Skip to content

Commit c7b3cf1

Browse files
committed
[INTERNAL] index.js: Add tests
1 parent a64fa38 commit c7b3cf1

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

test/lib/index.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
const test = require("ava");
2+
const index = require("../../index");
3+
4+
test("index.js exports all expected modules", (t) => {
5+
t.truthy(index.server, "Module exported");
6+
t.truthy(index.sslUtil, "Module exported");
7+
t.truthy(index.middlewareRepository, "Module exported");
8+
9+
t.truthy(index.middleware.csp, "Module exported");
10+
t.truthy(index.middleware.discovery, "Module exported");
11+
t.truthy(index.middleware.nonReadRequests, "Module exported");
12+
t.truthy(index.middleware.serveIndex, "Module exported");
13+
t.truthy(index.middleware.serveResources, "Module exported");
14+
t.truthy(index.middleware.serveThemes, "Module exported");
15+
t.truthy(index.middleware.versionInfo, "Module exported");
16+
});

0 commit comments

Comments
 (0)