Skip to content

Commit 067b2f3

Browse files
committed
test: Make more queries one line in tests
1 parent 4620b01 commit 067b2f3

File tree

2 files changed

+8
-20
lines changed

2 files changed

+8
-20
lines changed

src/__tests__/__snapshots__/api.tests.ts.snap

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -335,9 +335,7 @@ exports[`
335335
`;
336336

337337
exports[`
338-
findFeed(url: "https://non--------existing-domain.com") {
339-
link
340-
}
338+
findFeed(url: "https://non--------existing-domain.com") { link }
341339
1`] = `
342340
{
343341
"data": null,
@@ -364,9 +362,7 @@ exports[`
364362
`;
365363

366364
exports[`
367-
findFeed(url: "https://rolflekang.com") {
368-
link
369-
}
365+
findFeed(url: "https://rolflekang.com") { link }
370366
1`] = `
371367
{
372368
"data": {
@@ -383,9 +379,7 @@ exports[`
383379
`;
384380

385381
exports[`
386-
findFeed(url: "not-a-url") {
387-
link
388-
}
382+
findFeed(url: "not-a-url") { link }
389383
1`] = `
390384
{
391385
"data": null,

src/__tests__/api.tests.ts

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -52,25 +52,19 @@ testGraphqlApi`
5252
`;
5353

5454
testGraphqlApi`
55-
findFeed(url: "${websiteUrl}") {
56-
link
55+
feed(url: "${url}", startTime: "2020-01-01", endTime: "2020-10-31") {
56+
items { title }
5757
}
5858
`;
5959

6060
testGraphqlApi`
61-
feed(url: "${url}", startTime: "2020-01-01", endTime: "2020-10-31") {
62-
items { title }
63-
}
61+
findFeed(url: "${websiteUrl}") { link }
6462
`;
6563

6664
testGraphqlApi`
67-
findFeed(url: "not-a-url") {
68-
link
69-
}
65+
findFeed(url: "not-a-url") { link }
7066
`;
7167

7268
testGraphqlApi`
73-
findFeed(url: "https://non--------existing-domain.com") {
74-
link
75-
}
69+
findFeed(url: "https://non--------existing-domain.com") { link }
7670
`;

0 commit comments

Comments
 (0)