@expo/build-tools 1.0.75 → 1.0.76
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.
|
@@ -29,6 +29,10 @@ function createEasMaestroTestFunctionGroup(buildToolsContext) {
|
|
|
29
29
|
name: 'install_app',
|
|
30
30
|
displayName: `Install app to Simulator`,
|
|
31
31
|
command: `
|
|
32
|
+
# shopt -s nullglob is necessary not to try to install
|
|
33
|
+
# SEARCH_PATH literally if there are no matching files.
|
|
34
|
+
shopt -s nullglob
|
|
35
|
+
|
|
32
36
|
SEARCH_PATH="ios/build/Build/Products/*simulator/*.app"
|
|
33
37
|
FILES_FOUND=false
|
|
34
38
|
|
|
@@ -38,7 +42,7 @@ function createEasMaestroTestFunctionGroup(buildToolsContext) {
|
|
|
38
42
|
xcrun simctl install booted "$APP_PATH"
|
|
39
43
|
done
|
|
40
44
|
|
|
41
|
-
if ! FILES_FOUND;
|
|
45
|
+
if ! $FILES_FOUND; then
|
|
42
46
|
echo "No files found matching \\"$SEARCH_PATH\\". Are you sure you've built a Simulator app?"
|
|
43
47
|
exit 1
|
|
44
48
|
fi
|
|
@@ -54,6 +58,9 @@ function createEasMaestroTestFunctionGroup(buildToolsContext) {
|
|
|
54
58
|
command: `
|
|
55
59
|
# shopt -s globstar is necessary to add /**/ support
|
|
56
60
|
shopt -s globstar
|
|
61
|
+
# shopt -s nullglob is necessary not to try to install
|
|
62
|
+
# SEARCH_PATH literally if there are no matching files.
|
|
63
|
+
shopt -s nullglob
|
|
57
64
|
|
|
58
65
|
SEARCH_PATH="android/app/build/outputs/**/*.apk"
|
|
59
66
|
FILES_FOUND=false
|
|
@@ -64,7 +71,7 @@ function createEasMaestroTestFunctionGroup(buildToolsContext) {
|
|
|
64
71
|
adb install "$APP_PATH"
|
|
65
72
|
done
|
|
66
73
|
|
|
67
|
-
if ! FILES_FOUND;
|
|
74
|
+
if ! $FILES_FOUND; then
|
|
68
75
|
echo "No files found matching \\"$SEARCH_PATH\\". Are you sure you've built an Emulator app?"
|
|
69
76
|
exit 1
|
|
70
77
|
fi
|
|
@@ -87,7 +94,7 @@ function createEasMaestroTestFunctionGroup(buildToolsContext) {
|
|
|
87
94
|
ifCondition: '${ always() }',
|
|
88
95
|
name: 'Upload Maestro test results',
|
|
89
96
|
callInputs: {
|
|
90
|
-
path: '${ eas.env.HOME }/.maestro/',
|
|
97
|
+
path: '${ eas.env.HOME }/.maestro/tests',
|
|
91
98
|
ignore_error: true,
|
|
92
99
|
type: 'build-artifact',
|
|
93
100
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"maestroTest.js","sourceRoot":"","sources":["../../../src/steps/functionGroups/maestroTest.ts"],"names":[],"mappings":";;;AAAA,uCAKqB;AACrB,uDAA+C;AAG/C,gEAAgF;AAChF,sEAAsF;AACtF,4EAA4F;AAC5F,gEAAgF;AAEhF,SAAgB,iCAAiC,CAC/C,iBAAqC;IAErC,OAAO,IAAI,0BAAkB,CAAC;QAC5B,SAAS,EAAE,KAAK;QAChB,EAAE,EAAE,cAAc;QAClB,cAAc,EAAE;YACd,sBAAc,CAAC,cAAc,CAAC;gBAC5B,oBAAoB,EAAE,mCAA2B,CAAC,MAAM;gBACxD,EAAE,EAAE,WAAW;gBACf,QAAQ,EAAE,IAAI;aACf,CAAC;SACH;QACD,qCAAqC,EAAE,CAAC,SAAS,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE;YAC/D,MAAM,KAAK,GAAgB;gBACzB,IAAA,kDAAiC,GAAE,CAAC,+BAA+B,CAAC,SAAS,CAAC;aAC/E,CAAC;YAEF,IAAI,iBAAiB,CAAC,GAAG,CAAC,QAAQ,KAAK,wBAAQ,CAAC,GAAG,EAAE,CAAC;gBACpD,KAAK,CAAC,IAAI,CACR,IAAA,wDAAoC,GAAE,CAAC,+BAA+B,CAAC,SAAS,CAAC,CAClF,CAAC;gBACF,KAAK,CAAC,IAAI,CACR,IAAI,iBAAS,CAAC,SAAS,EAA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n BuildFunctionGroup,\n BuildStep,\n BuildStepInput,\n BuildStepInputValueTypeName,\n} from '@expo/steps';\nimport { Platform } from '@expo/eas-build-job';\n\nimport { CustomBuildContext } from '../../customBuildContext';\nimport { createInstallMaestroBuildFunction } from '../functions/installMaestro';\nimport { createStartIosSimulatorBuildFunction } from '../functions/startIosSimulator';\nimport { createStartAndroidEmulatorBuildFunction } from '../functions/startAndroidEmulator';\nimport { createUploadArtifactBuildFunction } from '../functions/uploadArtifact';\n\nexport function createEasMaestroTestFunctionGroup(\n buildToolsContext: CustomBuildContext\n): BuildFunctionGroup {\n return new BuildFunctionGroup({\n namespace: 'eas',\n id: 'maestro_test',\n inputProviders: [\n BuildStepInput.createProvider({\n allowedValueTypeName: BuildStepInputValueTypeName.STRING,\n id: 'flow_path',\n required: true,\n }),\n ],\n createBuildStepsFromFunctionGroupCall: (globalCtx, { inputs }) => {\n const steps: BuildStep[] = [\n createInstallMaestroBuildFunction().createBuildStepFromFunctionCall(globalCtx),\n ];\n\n if (buildToolsContext.job.platform === Platform.IOS) {\n steps.push(\n createStartIosSimulatorBuildFunction().createBuildStepFromFunctionCall(globalCtx)\n );\n steps.push(\n new BuildStep(globalCtx, {\n id: BuildStep.getNewId(),\n name: 'install_app',\n displayName: `Install app to Simulator`,\n command: `\n # shopt -s nullglob is necessary not to try to install\n # SEARCH_PATH literally if there are no matching files.\n shopt -s nullglob\n\n SEARCH_PATH=\"ios/build/Build/Products/*simulator/*.app\"\n FILES_FOUND=false\n\n for APP_PATH in $SEARCH_PATH; do\n FILES_FOUND=true\n echo \"Installing \\\\\"$APP_PATH\\\\\"\"\n xcrun simctl install booted \"$APP_PATH\"\n done\n \n if ! $FILES_FOUND; then\n echo \"No files found matching \\\\\"$SEARCH_PATH\\\\\". Are you sure you've built a Simulator app?\"\n exit 1\n fi\n `,\n })\n );\n } else if (buildToolsContext.job.platform === Platform.ANDROID) {\n steps.push(\n createStartAndroidEmulatorBuildFunction().createBuildStepFromFunctionCall(globalCtx)\n );\n steps.push(\n new BuildStep(globalCtx, {\n id: BuildStep.getNewId(),\n name: 'install_app',\n displayName: `Install app to Emulator`,\n command: `\n # shopt -s globstar is necessary to add /**/ support\n shopt -s globstar\n # shopt -s nullglob is necessary not to try to install\n # SEARCH_PATH literally if there are no matching files.\n shopt -s nullglob\n\n SEARCH_PATH=\"android/app/build/outputs/**/*.apk\"\n FILES_FOUND=false\n\n for APP_PATH in $SEARCH_PATH; do\n FILES_FOUND=true\n echo \"Installing \\\\\"$APP_PATH\\\\\"\"\n adb install \"$APP_PATH\"\n done\n \n if ! $FILES_FOUND; then\n echo \"No files found matching \\\\\"$SEARCH_PATH\\\\\". Are you sure you've built an Emulator app?\"\n exit 1\n fi\n `,\n })\n );\n }\n\n const flowPaths = `${inputs.flow_path.value}`\n .split('\\n') // It's easy to get an empty line with YAML\n .filter((entry) => entry);\n for (const flowPath of flowPaths) {\n steps.push(\n new BuildStep(globalCtx, {\n id: BuildStep.getNewId(),\n name: 'maestro_test',\n ifCondition: '${ always() }',\n displayName: `maestro test ${flowPath}`,\n command: `maestro test ${flowPath}`,\n })\n );\n }\n\n steps.push(\n createUploadArtifactBuildFunction(buildToolsContext).createBuildStepFromFunctionCall(\n globalCtx,\n {\n ifCondition: '${ always() }',\n name: 'Upload Maestro test results',\n callInputs: {\n path: '${ eas.env.HOME }/.maestro/tests',\n ignore_error: true,\n type: 'build-artifact',\n },\n }\n )\n );\n\n return steps;\n },\n });\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@expo/build-tools",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.76",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -69,5 +69,5 @@
|
|
|
69
69
|
"node": "20.11.0",
|
|
70
70
|
"yarn": "1.22.21"
|
|
71
71
|
},
|
|
72
|
-
"gitHead": "
|
|
72
|
+
"gitHead": "60afc7e1ceac6dbebd4fb6bb272e0f12eeda7fd7"
|
|
73
73
|
}
|