Skip to content

Commit e935d0b

Browse files
authored
build: remove iOS test runs (angular#30156)
Removes the tests that run against iOS. There are a couple of reasons to do so: * The tests haven't caught any issues in years. * The tests tend to be flaky. * They're running aginst iOS 15 which Angular no longer supports. We can't update to anything newer, because we would have to update our Saucelabs setup which will require dev infra time investment.
1 parent 75c8aa8 commit e935d0b

11 files changed

+57
-1815
lines changed

.github/workflows/ci.yml

+1-22
Original file line numberDiff line numberDiff line change
@@ -261,27 +261,6 @@ jobs:
261261
JOB_NAME: 'Docs site deployment'
262262
SLACK_BOT_TOKEN: ${{ secrets.ANGULAR_ROBOT_SLACK_TOKEN }}
263263

264-
saucelabs:
265-
runs-on: ubuntu-latest
266-
env:
267-
KARMA_PARALLEL_BROWSERS: 2
268-
CI_NODE_INDEX: 0
269-
CI_NODE_TOTAL: 1
270-
CI_RUNNER_NUMBER: ${{ github.run_id }}
271-
steps:
272-
- name: Initialize environment
273-
uses: angular/dev-infra/github-actions/npm/checkout-and-setup-node@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
274-
with:
275-
cache-node-modules: true
276-
- name: Install node modules
277-
run: yarn install --frozen-lockfile
278-
- name: Setup Bazel
279-
uses: angular/dev-infra/github-actions/bazel/setup@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
280-
- name: Setup Saucelabs Variables
281-
uses: angular/dev-infra/github-actions/saucelabs@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
282-
- name: Run tests on Saucelabs
283-
run: ./scripts/circleci/run-saucelabs-tests.sh
284-
285264
browserstack:
286265
runs-on: ubuntu-latest
287266
env:
@@ -297,7 +276,7 @@ jobs:
297276
run: yarn install --frozen-lockfile
298277
- name: Setup Bazel
299278
uses: angular/dev-infra/github-actions/bazel/setup@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
300-
- name: Setup Saucelabs Variables
279+
- name: Setup Browserstack Variables
301280
uses: angular/dev-infra/github-actions/browserstack@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
302281
- name: Run tests on Browserstack
303282
run: ./scripts/circleci/run-browserstack-tests.sh

.github/workflows/pr.yml

+1-24
Original file line numberDiff line numberDiff line change
@@ -189,29 +189,6 @@ jobs:
189189
name: Package Artifacts
190190
path: dist/release-archives
191191

192-
saucelabs:
193-
runs-on: ubuntu-latest
194-
env:
195-
KARMA_PARALLEL_BROWSERS: 2
196-
CI_NODE_INDEX: 0
197-
CI_NODE_TOTAL: 1
198-
CI_RUNNER_NUMBER: ${{ github.run_id }}
199-
steps:
200-
- name: Initialize environment
201-
uses: angular/dev-infra/github-actions/npm/checkout-and-setup-node@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
202-
with:
203-
cache-node-modules: true
204-
# Checking out the pull request commit is intended here as we need to run the changed code tests.
205-
ref: ${{ github.event.pull_request.head.sha }}
206-
- name: Install node modules
207-
run: yarn install --frozen-lockfile
208-
- name: Setup Bazel
209-
uses: angular/dev-infra/github-actions/bazel/setup@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
210-
- name: Setup Saucelabs Variables
211-
uses: angular/dev-infra/github-actions/saucelabs@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
212-
- name: Run tests on Saucelabs
213-
run: ./scripts/circleci/run-saucelabs-tests.sh
214-
215192
browserstack:
216193
runs-on: ubuntu-latest
217194
env:
@@ -229,7 +206,7 @@ jobs:
229206
run: yarn install --frozen-lockfile
230207
- name: Setup Bazel
231208
uses: angular/dev-infra/github-actions/bazel/setup@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
232-
- name: Setup Saucelabs Variables
209+
- name: Setup Browserstack Variables
233210
uses: angular/dev-infra/github-actions/browserstack@40b2cbdbcc40f36f125d721c4e8decd3bb607ea4
234211
- name: Run tests on Browserstack
235212
run: ./scripts/circleci/run-browserstack-tests.sh

package.json

-1
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,6 @@
143143
"karma-jasmine": "^4.0.1",
144144
"karma-parallel": "^0.3.1",
145145
"karma-requirejs": "^1.1.0",
146-
"karma-sauce-launcher": "^4.3.6",
147146
"karma-sourcemap-loader": "^0.3.8",
148147
"luxon": "^3.0.0",
149148
"madge": "^4.0.0",

scripts/circleci/run-saucelabs-tests.sh

-32
This file was deleted.

scripts/saucelabs/start-tunnel.sh

-38
This file was deleted.

scripts/saucelabs/stop-tunnel.sh

-23
This file was deleted.

scripts/saucelabs/wait-tunnel.sh

-28
This file was deleted.

test/browser-providers.js

-3
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,8 @@
22
* Browser Configuration for the different jobs in the legacy Karma tests.
33
*
44
* - `browserstack`: Launches the browser within BrowserStack
5-
* - `saucelabs`: Launches the browser within Saucelabs
65
*/
76
const browserConfig = {
8-
'iOS15': {unitTest: {target: 'saucelabs'}},
97
'Safari16': {unitTest: {target: 'browserstack'}},
108
};
119

@@ -14,7 +12,6 @@ exports.customLaunchers = require('./karma-browsers.json');
1412

1513
/** Exports a map of configured browsers, which should run in the given platform. */
1614
exports.platformMap = {
17-
'saucelabs': buildConfiguration('unitTest', 'saucelabs'),
1815
'browserstack': buildConfiguration('unitTest', 'browserstack'),
1916
};
2017

test/karma-browsers.json

-9
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,4 @@
11
{
2-
"SAUCELABS_IOS15": {
3-
"base": "SauceLabs",
4-
"appiumVersion": "1.22.0",
5-
"deviceOrientation": "portrait",
6-
"browserName": "Safari",
7-
"platformVersion": "15.0",
8-
"platformName": "iOS",
9-
"deviceName": "iPhone 13 Pro Max Simulator"
10-
},
112
"BROWSERSTACK_SAFARI16": {
123
"base": "BrowserStack",
134
"browser": "Safari",

test/karma.conf.js

-17
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ module.exports = config => {
99
plugins: [
1010
require('karma-jasmine'),
1111
require('karma-browserstack-launcher'),
12-
require('karma-sauce-launcher'),
1312
require('karma-sourcemap-loader'),
1413
{
1514
'middleware:fake-url': [
@@ -72,16 +71,6 @@ module.exports = config => {
7271
reporters: ['dots'],
7372
autoWatch: false,
7473

75-
sauceLabs: {
76-
testName: 'Angular Material Unit Tests',
77-
startConnect: false,
78-
recordVideo: false,
79-
recordScreenshots: false,
80-
idleTimeout: 1000,
81-
commandTimeout: 600,
82-
maxDuration: 5400,
83-
},
84-
8574
browserStack: {
8675
project: 'Angular Material Unit Tests',
8776
startTunnel: true,
@@ -134,12 +123,6 @@ module.exports = config => {
134123
if (testPlatform === 'browserstack') {
135124
config.browserStack.build = buildIdentifier;
136125
config.browserStack.tunnelIdentifier = tunnelIdentifier;
137-
} else if (testPlatform === 'saucelabs') {
138-
config.sauceLabs.build = buildIdentifier;
139-
config.sauceLabs.tunnelIdentifier = tunnelIdentifier;
140-
// Setup the saucelabs reporter so that we report back to Saucelabs once
141-
// our tests finished.
142-
config.reporters.push('saucelabs');
143126
}
144127

145128
// If the test platform is not "local", browsers are launched externally and can take

0 commit comments

Comments
 (0)