Test pr metadata in CLI preview

This commit is contained in:
Toshiya Doi 2020-04-04 13:14:34 +09:00
parent 0cb6890c74
commit 85d8f808f2
4 changed files with 310 additions and 28 deletions

View file

@ -10,6 +10,29 @@
"author": {
"login": "nobody"
},
"assignees": {
"nodes": [],
"totalcount": 0
},
"labels": {
"nodes": [],
"totalcount": 0
},
"projectcards": {
"nodes": [],
"totalcount": 0
},
"milestone": {
"title": ""
},
"participants": {
"nodes": [
{
"login": "marseilles"
}
],
"totalcount": 1
},
"commits": {
"totalCount": 12
},

View file

@ -0,0 +1,100 @@
{
"data": {
"repository": {
"pullRequest": {
"number": 12,
"title": "Blueberries are from a fork",
"state": "OPEN",
"body": "**blueberries taste good**",
"url": "https://github.com/OWNER/REPO/pull/12",
"author": {
"login": "nobody"
},
"assignees": {
"nodes": [
{
"login": "marseilles"
},
{
"login": "monaco"
},
{
"login": "montpellier"
}
],
"totalcount": 4
},
"labels": {
"nodes": [
{
"name": "one"
},
{
"name": "two"
},
{
"name": "three"
}
],
"totalcount": 4
},
"projectcards": {
"nodes": [
{
"project": {
"name": "Project 1"
},
"column": {
"name": "column A"
}
},
{
"project": {
"name": "Project 2"
},
"column": {
"name": "column B"
}
},
{
"project": {
"name": "Project 3"
},
"column": {
"name": "column C"
}
}
],
"totalcount": 4
},
"milestone": {
"title": "uluru"
},
"participants": {
"nodes": [
{
"login": "marseilles"
},
{
"login": "monaco"
},
{
"login": "montpellier"
}
],
"totalcount": 4
},
"commits": {
"totalCount": 12
},
"baseRefName": "master",
"headRefName": "blueberries",
"headRepositoryOwner": {
"login": "hubot"
},
"isCrossRepository": true,
"isDraft": false
}
}
}
}

View file

@ -0,0 +1,126 @@
{
"data": {
"repository": {
"pullRequests": {
"nodes": [
{
"number": 12,
"title": "Blueberries are from a fork",
"state": "OPEN",
"body": "yeah",
"url": "https://github.com/OWNER/REPO/pull/12",
"headRefName": "blueberries",
"baseRefName": "master",
"headRepositoryOwner": {
"login": "hubot"
},
"assignees": {
"nodes": [],
"totalcount": 0
},
"labels": {
"nodes": [],
"totalcount": 0
},
"projectcards": {
"nodes": [],
"totalcount": 0
},
"milestone": {},
"participants": {
"nodes": [
{
"login": "nobody"
}
],
"totalcount": 1
},
"commits": {
"totalCount": 12
},
"author": {
"login": "nobody"
},
"isCrossRepository": true,
"isDraft": false
},
{
"number": 10,
"title": "Blueberries are a good fruit",
"state": "OPEN",
"body": "**blueberries taste good**",
"url": "https://github.com/OWNER/REPO/pull/10",
"baseRefName": "master",
"headRefName": "blueberries",
"author": {
"login": "nobody"
},
"assignees": {
"nodes": [
{
"login": "marseilles"
},
{
"login": "monaco"
}
],
"totalcount": 2
},
"labels": {
"nodes": [
{
"name": "one"
},
{
"name": "two"
},
{
"name": "three"
}
],
"totalcount": 3
},
"projectcards": {
"nodes": [
{
"project": {
"name": "The GitHub CLI"
},
"column": {
"name": "to do list"
}
}
],
"totalcount": 1
},
"milestone": {
"title": "uluru"
},
"participants": {
"nodes": [
{
"login": "marseilles"
},
{
"login": "monaco"
},
{
"login": "montpellier"
}
],
"totalcount": 3
},
"headRepositoryOwner": {
"login": "OWNER"
},
"commits": {
"totalCount": 8
},
"isCrossRepository": false,
"isDraft": false
}
]
}
}
}
}