This repository was archived by the owner on Jun 27, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathinstall-starterkit.test.js
More file actions
57 lines (49 loc) · 2.08 KB
/
install-starterkit.test.js
File metadata and controls
57 lines (49 loc) · 2.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
const tap = require('tap');
const installStarterkit = require('../bin/install-starterkit');
const wrapAsync = require('../bin/utils').wrapAsync;
const getUniqueProjectPath = require('./utils/getUniqueProjectPath');
const moduleExist = require.resolve;
const projectRoot = getUniqueProjectPath();
const minimalConfig = {
paths: {
source: {
root: projectRoot
}
}
};
tap.test('Install starterkit-mustache-demo ->', t => wrapAsync(function*() {
yield installStarterkit('@pattern-lab/starterkit-mustache-demo', minimalConfig);
const pkg = yield moduleExist('@pattern-lab/starterkit-mustache-demo');
t.ok(pkg, 'module should exist after install');
t.end();
}));
tap.test('Install starterkit-mustache-base ->', t => wrapAsync(function*() {
yield installStarterkit('@pattern-lab/starterkit-mustache-base', minimalConfig);
const pkg = yield moduleExist('@pattern-lab/starterkit-mustache-base');
t.ok(pkg, 'module should exist after install');
t.end();
}));
tap.test('Install starterkit-mustache-bootstrap ->', t => wrapAsync(function*() {
yield installStarterkit('starterkit-mustache-bootstrap', minimalConfig);
const pkg = yield moduleExist('starterkit-mustache-bootstrap');
t.ok(pkg, 'module should exist after install');
t.end();
}));
tap.test('Install starterkit-mustache-foundation ->', t => wrapAsync(function*() {
yield installStarterkit('starterkit-mustache-foundation', minimalConfig);
const pkg = yield moduleExist('starterkit-mustache-foundation');
t.ok(pkg, 'module should exist after install');
t.end();
}));
tap.test('Install starterkit-mustache-acidtest ->', t => wrapAsync(function*() {
yield installStarterkit('starterkit-mustache-acidtest', minimalConfig);
const pkg = yield moduleExist('starterkit-mustache-acidtest');
t.ok(pkg, 'module should exist after install');
t.end();
}));
tap.test('Install starterkit-mustache-materialdesign ->', t => wrapAsync(function*() {
yield installStarterkit('starterkit-mustache-materialdesign', minimalConfig);
const pkg = yield moduleExist('starterkit-mustache-materialdesign');
t.ok(pkg, 'module should exist after install');
t.end();
}));