Skip to content

Commit 2619dbe

Browse files
committed
test: improve covers
1 parent dc11b32 commit 2619dbe

File tree

1 file changed

+18
-2
lines changed

1 file changed

+18
-2
lines changed

plugins/navigation.schema.test.ts

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,18 @@ describe("pĺugins/navigation.directive#NavigationDirectives", () => {
1919
})
2020

2121
test("plugin return navigation", () => {
22-
const plugin = new NavigationSchema(schema.data.__schema, projectPackage, {});
22+
const plugin = new NavigationSchema(
23+
{
24+
...schema.data.__schema,
25+
subscriptionType: {
26+
"name": "Subscription",
27+
"description": "The subscription root of GitHub's GraphQL interface.",
28+
"kind": "OBJECT"
29+
},
30+
},
31+
projectPackage,
32+
{}
33+
);
2334
expect(plugin.getNavigations("Query")).toEqual([
2435
{
2536
title: "Schema",
@@ -33,7 +44,12 @@ describe("pĺugins/navigation.directive#NavigationDirectives", () => {
3344
"href": "/mutation.doc.html",
3445
"isActive": false,
3546
"text": "Mutation",
36-
}
47+
},
48+
{
49+
"href": "/subscription.doc.html",
50+
"isActive": false,
51+
"text": "Subscription"
52+
},
3753
]
3854
}
3955
]);

0 commit comments

Comments
 (0)