File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed
Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -130,7 +130,8 @@ jobs:
130130 working-directory : test-automation
131131 run : npm run e2e:regression:test
132132 env :
133- BASE_URL : ${{ needs.build-app.result == 'success' && 'http://localhost:3000' || '' }}
133+ ENV_NAME : ${{ (github.event_name == 'push' || github.event_name == 'pull_request') && 'local' || 'test' }}
134+ BASE_URL_LOCAL : ' http://localhost:3000'
134135 - name : Generate Allure Report
135136 if : ${{ !cancelled() }}
136137 working-directory : test-automation
Original file line number Diff line number Diff line change @@ -34,6 +34,13 @@ function loadEnvironmentConfig() {
3434
3535 console . log ( `Global setup: Loading environment '${ envName } '` )
3636
37+ // Local CI build: use BASE_URL_LOCAL directly
38+ if ( envName === 'local' && process . env . BASE_URL_LOCAL ) {
39+ process . env . BASE_URL = process . env . BASE_URL_LOCAL
40+ console . log ( `Global setup: Using BASE_URL_LOCAL: ${ process . env . BASE_URL } ` )
41+ return { envName, envFilePath }
42+ }
43+
3744 // In CI, pick BASE_URL based on ENV_NAME
3845 if ( process . env . BASE_URL_TEST || process . env . BASE_URL_DEV ) {
3946 process . env . BASE_URL = envName === 'test'
You can’t perform that action at this time.
0 commit comments