File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ "use strict" ;
Original file line number Diff line number Diff line change 1+ name : React Native Harness for Web
2+ description : Run React Native Harness tests on Web
3+ inputs :
4+ runner :
5+ description : The runner to use
6+ required : true
7+ type : string
8+ projectRoot :
9+ description : The project root directory
10+ required : false
11+ type : string
12+ uploadVisualTestArtifacts :
13+ description : Whether to upload visual test diff and actual images as artifacts
14+ required : false
15+ type : boolean
16+ default : ' true'
17+ runs :
18+ using : ' composite'
19+ steps :
20+ - name : Load React Native Harness configuration
21+ id : load-config
22+ shell : bash
23+ env :
24+ INPUT_RUNNER : ${{ inputs.runner }}
25+ INPUT_PROJECTROOT : ${{ inputs.projectRoot }}
26+ run : |
27+ node ${{ github.action_path }}/../shared/index.cjs
28+ - name : Install Playwright Browsers
29+ shell : bash
30+ run : npx playwright install --with-deps chromium
31+ - name : Run E2E tests
32+ shell : bash
33+ working-directory : ${{ inputs.projectRoot }}
34+ run : |
35+ pnpm react-native-harness --harnessRunner ${{ inputs.runner }}
36+ - name : Upload visual test artifacts
37+ if : always() && inputs.uploadVisualTestArtifacts == 'true'
38+ uses : actions/upload-artifact@v4
39+ with :
40+ name : visual-test-diffs-chromium
41+ path : |
42+ ${{ inputs.projectRoot }}/**/__image_snapshots__/**/*-diff.png
43+ ${{ inputs.projectRoot }}/**/__image_snapshots__/**/*-actual.png
44+ if-no-files-found : ignore
Original file line number Diff line number Diff line change 1+ // This file is intentionally empty.
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ import fs from 'node:fs';
33import path from 'node:path' ;
44
55const OUT_DIR = path . resolve ( '../../actions' ) ;
6- const TARGETS = [ 'ios' , 'android' ] ;
6+ const TARGETS = [ 'ios' , 'android' , 'web' ] ;
77
88const packageJson = JSON . parse (
99 fs . readFileSync ( path . resolve ( './package.json' ) , 'utf8' )
Original file line number Diff line number Diff line change 33 "files" : [],
44 "include" : [],
55 "references" : [
6- {
7- "path" : " ../config"
8- },
9- {
10- "path" : " ../tools"
11- },
126 {
137 "path" : " ../platforms"
148 },
Original file line number Diff line number Diff line change 1212 },
1313 "include" : [" src/**/*.ts" ],
1414 "references" : [
15- {
16- "path" : " ../config/tsconfig.lib.json"
17- },
18- {
19- "path" : " ../tools/tsconfig.lib.json"
20- },
2115 {
2216 "path" : " ../platforms/tsconfig.lib.json"
2317 }
You can’t perform that action at this time.
0 commit comments