@zapier/zapier-sdk-cli 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/test/cli.test.ts +16 -16
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zapier/zapier-sdk-cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"description": "Command line interface for Zapier SDK",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"inquirer": "^12.6.3",
|
|
26
26
|
"ora": "^8.2.0",
|
|
27
27
|
"zod": "^3.25.67",
|
|
28
|
-
"@zapier/zapier-sdk": "0.0.
|
|
28
|
+
"@zapier/zapier-sdk": "0.0.3"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@types/inquirer": "^9.0.8",
|
package/test/cli.test.ts
CHANGED
|
@@ -3,44 +3,44 @@ import { execSync } from "child_process";
|
|
|
3
3
|
import path from "path";
|
|
4
4
|
|
|
5
5
|
describe("Zapier CLI", () => {
|
|
6
|
-
const cliPath = path.join(__dirname, "../bin/zapier.js");
|
|
6
|
+
const cliPath = path.join(__dirname, "../bin/zapier-sdk.js");
|
|
7
7
|
|
|
8
8
|
it("should show help when called with --help", () => {
|
|
9
9
|
const output = execSync(`node ${cliPath} --help`, { encoding: "utf8" });
|
|
10
10
|
|
|
11
11
|
expect(output).toContain("CLI for Zapier SDK");
|
|
12
12
|
expect(output).toContain("Commands:");
|
|
13
|
-
expect(output).toContain("
|
|
13
|
+
expect(output).toContain("apps");
|
|
14
|
+
expect(output).toContain("actions");
|
|
14
15
|
});
|
|
15
16
|
|
|
16
|
-
it("should show
|
|
17
|
-
const output = execSync(`node ${cliPath}
|
|
17
|
+
it("should show apps help when called with apps --help", () => {
|
|
18
|
+
const output = execSync(`node ${cliPath} apps --help`, {
|
|
18
19
|
encoding: "utf8",
|
|
19
20
|
});
|
|
20
21
|
|
|
21
|
-
expect(output).toContain("
|
|
22
|
-
expect(output).toContain("
|
|
23
|
-
expect(output).toContain("
|
|
22
|
+
expect(output).toContain("apps management commands");
|
|
23
|
+
expect(output).toContain("list");
|
|
24
|
+
expect(output).toContain("get");
|
|
24
25
|
});
|
|
25
26
|
|
|
26
|
-
it("should show
|
|
27
|
-
const output = execSync(`node ${cliPath}
|
|
27
|
+
it("should show apps list help when called with apps list --help", () => {
|
|
28
|
+
const output = execSync(`node ${cliPath} apps list --help`, {
|
|
28
29
|
encoding: "utf8",
|
|
29
30
|
});
|
|
30
31
|
|
|
31
|
-
expect(output).toContain("List all available apps");
|
|
32
32
|
expect(output).toContain("--category");
|
|
33
33
|
expect(output).toContain("--limit");
|
|
34
34
|
});
|
|
35
35
|
|
|
36
|
-
it("should show
|
|
37
|
-
const output = execSync(`node ${cliPath}
|
|
36
|
+
it("should show actions help when called with actions --help", () => {
|
|
37
|
+
const output = execSync(`node ${cliPath} actions --help`, {
|
|
38
38
|
encoding: "utf8",
|
|
39
39
|
});
|
|
40
40
|
|
|
41
|
-
expect(output).toContain("
|
|
42
|
-
expect(output).toContain("
|
|
43
|
-
expect(output).toContain("
|
|
44
|
-
expect(output).toContain("
|
|
41
|
+
expect(output).toContain("actions management commands");
|
|
42
|
+
expect(output).toContain("list");
|
|
43
|
+
expect(output).toContain("get");
|
|
44
|
+
expect(output).toContain("run");
|
|
45
45
|
});
|
|
46
46
|
});
|