-
-
Notifications
You must be signed in to change notification settings - Fork 27
Expand file tree
/
Copy pathexec.test.js
More file actions
39 lines (30 loc) · 1.04 KB
/
exec.test.js
File metadata and controls
39 lines (30 loc) · 1.04 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
const cmp = require('semver-compare');
const { emacsVersion, TestContext } = require("./helpers");
describe("exec", () => {
const ctx = new TestContext("./test/jest/exec");
beforeAll(async () => {
await ctx.runEask(
"install-deps", { timeout: 40000 },
// See https://github.com/emacs-eask/cli/issues/11.
cmp(await emacsVersion(), "28.1") == -1);
});
afterAll(() => ctx.cleanUp());
test("eask exec ert-runner", async () => {
await ctx.runEask("exec ert-runner -h");
});
test("eask exec github-elpa", async () => {
await ctx.runEask("exec github-elpa -h");
});
test("eask exec echo", async () => {
await ctx.runEask("exec echo hello world");
});
test("eask exec buttercup -L .", async () => {
await ctx.runEask("exec buttercup -L .");
});
test("eask exec buttercup -L . --pattern 'pattern 1'", async () => {
await ctx.runEask('exec buttercup -L . --pattern "pattern 1"');
});
test("should error with no args", async () => {
await expect(ctx.runEask("exec")).rejects.toThrow();
});
});