|
59 | 59 | ngx new --no-analytics --automate "$CWD/$file" "$TEST_APP_NAME" --no-insights |
60 | 60 | npm run test:ci |
61 | 61 |
|
62 | | - # force specific puppeteer/webdriver version to match up |
63 | | - if [ "$NGX_PACKAGE_MANAGER" == "yarn" ]; then |
64 | | - yarn add npm i puppeteer@12.0.1 |
65 | | - # yarn run webdriver-manager update --versions.chrome 79.0.3945.36 --gecko=false |
| 62 | + USE_PROTRACTOR=$(npm list --depth 0 --parseable protractor) |
| 63 | + |
| 64 | + if [ -z "$USE_PROTRACTOR" ]; then |
| 65 | + # force specific puppeteer/webdriver version to match up |
| 66 | + if [ "$NGX_PACKAGE_MANAGER" == "yarn" ]; then |
| 67 | + yarn add npm i puppeteer@16.2.0 |
| 68 | + yarn run webdriver-manager update --versions.chrome 104.0.5112.79 --gecko=false |
| 69 | + else |
| 70 | + npm i puppeteer@16.2.0 |
| 71 | + npx webdriver-manager update --versions.chrome 104.0.5112.79 --gecko=false |
| 72 | + fi |
| 73 | + |
| 74 | + # force usage of local chrome binary, in headless mode |
| 75 | + PROTRACTOR_CHROME_BIN=$(node -p "require('puppeteer').executablePath()") \ |
| 76 | + PROTRACTOR_CHROME_ARGS='["lang=en-US","--headless","--disable-gpu","--window-size=1024,768"]' \ |
| 77 | + npm run e2e --if-present -- --webdriver-update=false |
66 | 78 | else |
67 | | - npm i puppeteer@12.0.1 |
68 | | - # npx webdriver-manager update --versions.chrome 79.0.3945.36 --gecko=false |
| 79 | + npm run e2e:ci --if-present |
69 | 80 | fi |
70 | 81 |
|
71 | | - # force usage of local chrome binary, in headless mode |
72 | | - PROTRACTOR_CHROME_BIN=$(node -p "require('puppeteer').executablePath()") \ |
73 | | - PROTRACTOR_CHROME_ARGS='["lang=en-US","--headless","--disable-gpu","--window-size=1024,768"]' \ |
74 | | - npm run e2e --if-present # -- --webdriver-update=false |
75 | | - |
| 82 | + npm run e2e --if-present |
76 | 83 | npm run build -- --no-progress |
77 | 84 |
|
78 | 85 | if [ -n "$TEST_ANDROID" ]; then |
|
0 commit comments