Skip to content

Commit

Permalink
docs: update info on how to update artifacts snapshots for e2e (wix#973)
Browse files Browse the repository at this point in the history
  • Loading branch information
noomorph authored and rotemmiz committed Oct 8, 2018
1 parent aaaf798 commit 60cb52a
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions docs/Guide.Contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,18 @@ on macOS environment variables can be exported to desktop applications by adding
launchctl setenv PATH $PATH
```

##### Changing Detox e2e test suite

If you add, rename, or delete a test in `detox/test/e2e` suite, you also have to update Jest snapshots
of expected artifacts. It is usually done in five steps:

1. In `detox/test` project, run all end-to-end tests on iOS with `npm run e2e:ios-multi`.
2. Update the snapshots with: `npm run verify-artifacts:ios -- -u`.
3. Re-run Android tests with `npm run e2e:android`.
4. Update the snapshots with: `npm run verify-artifacts:android -- -u`.
5. Add the snapshots to your Git commit:
* Android: `detox/test/scripts/__snapshots__/verify_artifacts_are_not_missing.android.test.js.snap`
* iOS: `detox/test/scripts/__snapshots__/verify_artifacts_are_not_missing.ios.test.js.snap`

#### 3. Android Native tests

Expand Down

0 comments on commit 60cb52a

Please sign in to comment.