@applicaster/zapplicaster-cli 14.0.0-alpha.3881160800 → 14.0.0-alpha.3890252181
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 +9 -12
- package/src/commands/prepareWorkspace/__tests__/appBootstrapper.test.js +3 -3
- package/src/commands/prepareWorkspace/appBootstrapper.js +18 -0
- package/src/commands/publishPlugin/__tests__/__snapshots__/npmPublish.test.js.snap +0 -2
- package/src/commands/publishPlugin/__tests__/npmPublish.test.js +1 -2
- package/src/templates/newWorkspaceTemplate/index.js +3 -5
- package/src/zapp/__tests__/zapp.test.js +3 -3
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applicaster/zapplicaster-cli",
|
|
3
|
-
"version": "14.0.0-alpha.
|
|
3
|
+
"version": "14.0.0-alpha.3890252181",
|
|
4
4
|
"description": "CLI Tool for the zapp app and Quick Brick project",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
8
8
|
},
|
|
9
9
|
"engines": {
|
|
10
|
-
"node": ">=
|
|
11
|
-
"yarn": "^
|
|
10
|
+
"node": "^8.0.0 || >= 12.0.0",
|
|
11
|
+
"yarn": "^1.3.2"
|
|
12
12
|
},
|
|
13
13
|
"bin": "./index.js",
|
|
14
14
|
"repository": {
|
|
@@ -28,10 +28,10 @@
|
|
|
28
28
|
},
|
|
29
29
|
"homepage": "https://github.com/applicaster/quickbrick#readme",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@applicaster/zapp-react-dom-cli-template": "14.0.0-alpha.
|
|
32
|
-
"@applicaster/zapp-react-native-android-tv-cli-template": "14.0.0-alpha.
|
|
33
|
-
"@applicaster/zapp-react-native-cli-template": "14.0.0-alpha.
|
|
34
|
-
"@applicaster/zapp-react-native-tvos-cli-template": "14.0.0-alpha.
|
|
31
|
+
"@applicaster/zapp-react-dom-cli-template": "14.0.0-alpha.3890252181",
|
|
32
|
+
"@applicaster/zapp-react-native-android-tv-cli-template": "14.0.0-alpha.3890252181",
|
|
33
|
+
"@applicaster/zapp-react-native-cli-template": "14.0.0-alpha.3890252181",
|
|
34
|
+
"@applicaster/zapp-react-native-tvos-cli-template": "14.0.0-alpha.3890252181",
|
|
35
35
|
"axios": "^0.28.0",
|
|
36
36
|
"camelize": "^1.0.0",
|
|
37
37
|
"chalk": "^2.3.2",
|
|
@@ -57,17 +57,14 @@
|
|
|
57
57
|
"core-js": "*",
|
|
58
58
|
"immer": "*",
|
|
59
59
|
"react": "*",
|
|
60
|
-
"react-dom": "*",
|
|
61
60
|
"react-native": "*",
|
|
62
61
|
"react-native-fs": "*",
|
|
63
|
-
"react-native-gesture-handler": "*",
|
|
64
62
|
"react-native-linear-gradient": "*",
|
|
63
|
+
"react-native-safe-area-context": "*",
|
|
65
64
|
"react-native-svg": "*",
|
|
66
|
-
"react-native-web": "*",
|
|
67
65
|
"react-native-webview": "*",
|
|
68
66
|
"uglify-js": "*",
|
|
69
67
|
"validate-color": "*",
|
|
70
68
|
"zustand": "*"
|
|
71
|
-
}
|
|
72
|
-
"gitHead": "a473487564142c55cdb50f02505cf0b60fe75658"
|
|
69
|
+
}
|
|
73
70
|
}
|
|
@@ -85,11 +85,11 @@ const {
|
|
|
85
85
|
getPluginDependencies,
|
|
86
86
|
} = require("../../../plugins");
|
|
87
87
|
|
|
88
|
-
const mockedRenderTemplateFileCurried = jest.fn(
|
|
88
|
+
const mockedRenderTemplateFileCurried = jest.fn(Promise.resolve);
|
|
89
89
|
|
|
90
90
|
jest.mock("../../../render", () => ({
|
|
91
|
-
injectDependencies: jest.fn(
|
|
92
|
-
injectScripts: jest.fn(
|
|
91
|
+
injectDependencies: jest.fn(Promise.resolve),
|
|
92
|
+
injectScripts: jest.fn(Promise.resolve),
|
|
93
93
|
renderTemplateFile: jest.fn(() => mockedRenderTemplateFileCurried),
|
|
94
94
|
}));
|
|
95
95
|
|
|
@@ -38,6 +38,24 @@ async function patchPackages() {
|
|
|
38
38
|
existsSync(join(process.cwd(), "development-app", "patch_rn.js"))
|
|
39
39
|
) {
|
|
40
40
|
exec(`node ${process.cwd()}/development-app/patch_rn.js`);
|
|
41
|
+
} else if (
|
|
42
|
+
existsSync(
|
|
43
|
+
join(
|
|
44
|
+
process.cwd(),
|
|
45
|
+
"packages",
|
|
46
|
+
"zapp-react-dom-development-app",
|
|
47
|
+
"patch_rn.js"
|
|
48
|
+
)
|
|
49
|
+
)
|
|
50
|
+
) {
|
|
51
|
+
const pathToFile = join(
|
|
52
|
+
process.cwd(),
|
|
53
|
+
"packages",
|
|
54
|
+
"zapp-react-dom-development-app",
|
|
55
|
+
"patch_rn.js"
|
|
56
|
+
);
|
|
57
|
+
|
|
58
|
+
exec(`node ${pathToFile}`);
|
|
41
59
|
} else {
|
|
42
60
|
logger.log("Cannot patch packages, can't find the patch_rn.js file");
|
|
43
61
|
}
|
|
@@ -1,5 +1,3 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
3
|
exports[`npm publish step with default options throws if the npm command fails 1`] = `[Error: Failed to publish package]`;
|
|
4
|
-
|
|
5
|
-
exports[`npm publish step with dry run flag throws if used with the yarn flag as well 1`] = `true`;
|
|
@@ -154,8 +154,7 @@ describe("npm publish step", () => {
|
|
|
154
154
|
// didn't work
|
|
155
155
|
it.skip("throws if used with the yarn flag as well", async () => {
|
|
156
156
|
const configuration = getConfig({ dryRun: true, yarn: true });
|
|
157
|
-
|
|
158
|
-
expect(res).toMatchSnapshot();
|
|
157
|
+
expect(npmPublish(configuration)).rejects.toMatchSnapshot();
|
|
159
158
|
});
|
|
160
159
|
});
|
|
161
160
|
|
|
@@ -61,18 +61,16 @@ const template = {
|
|
|
61
61
|
version: "^3.1.0",
|
|
62
62
|
type: "devDependencies",
|
|
63
63
|
},
|
|
64
|
-
{ name: "flow-bin", version: "^0.107.0", type: "devDependencies" },
|
|
65
64
|
{ name: "jest", version: "^23.6.0", type: "devDependencies" },
|
|
66
65
|
{ name: "jest-extended", version: "^0.6.0", type: "devDependencies" },
|
|
67
66
|
{ name: "jest-html-reporter", version: "^2.3.0", type: "devDependencies" },
|
|
68
67
|
{ name: "lerna", version: "^2.11.0", type: "devDependencies" },
|
|
69
|
-
{ name: "ramda", version: "0.26.1", type: "devDependencies" },
|
|
70
68
|
{
|
|
71
|
-
name: "react-
|
|
72
|
-
version: "^
|
|
69
|
+
name: "metro-react-native-babel-preset",
|
|
70
|
+
version: "^0.59",
|
|
73
71
|
type: "devDependencies",
|
|
74
72
|
},
|
|
75
|
-
{ name: "
|
|
73
|
+
{ name: "ramda", version: "0.26.1", type: "devDependencies" },
|
|
76
74
|
{ name: "react-test-renderer", version: "16.4.1", type: "devDependencies" },
|
|
77
75
|
{
|
|
78
76
|
name: "regenerator-runtime",
|
|
@@ -25,13 +25,13 @@ describe("when ZAPP_TOKEN is not defined", () => {
|
|
|
25
25
|
process.env = ENV;
|
|
26
26
|
});
|
|
27
27
|
|
|
28
|
-
it("throws an error", () => {
|
|
29
|
-
const { getAppVersionParams } = require("../");
|
|
28
|
+
it("throws an error", async () => {
|
|
29
|
+
const { getAppVersionParams } = require("../index");
|
|
30
30
|
|
|
31
31
|
const ERROR_MESSAGE =
|
|
32
32
|
"no $ZAPP_TOKEN defined - please add it to your environment variables";
|
|
33
33
|
|
|
34
|
-
expect(getAppVersionParams(VERSION_ID)).rejects.
|
|
34
|
+
expect(getAppVersionParams(VERSION_ID)).rejects.toEqual(ERROR_MESSAGE);
|
|
35
35
|
});
|
|
36
36
|
});
|
|
37
37
|
|