File tree 1 file changed +5
-4
lines changed
1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -160,8 +160,9 @@ exists node_modules/react-scripts-fork
160
160
cd " $temp_app_path "
161
161
# we will install a non-existing package to simulate a failed installataion.
162
162
npx create-react-app --scripts-version=` date +%s` test-app-should-not-exist || true
163
- # confirm that the project folder was deleted
164
- test ! -d test-app-should-not-exist
163
+ # confirm that the project files were deleted
164
+ test ! -e test-app-should-not-exist/package.json
165
+ test ! -d test-app-should-not-exist/node_modules
165
166
166
167
# ******************************************************************************
167
168
# Test project folder is not deleted when creating app over existing folder
@@ -174,8 +175,8 @@ echo '## Hello' > ./test-app-should-remain/README.md
174
175
npx create-react-app --scripts-version=` date +%s` test-app-should-remain || true
175
176
# confirm the file exist
176
177
test -e test-app-should-remain/README.md
177
- # confirm only README.md is the only file in the directory
178
- if [ " $( ls -1 ./test-app-should-remain | wc -l | tr -d ' [:space:]' ) " != " 1 " ]; then
178
+ # confirm only README.md and error log are the only files in the directory
179
+ if [ " $( ls -1 ./test-app-should-remain | wc -l | tr -d ' [:space:]' ) " != " 2 " ]; then
179
180
false
180
181
fi
181
182
You can’t perform that action at this time.
0 commit comments