Skip to content

Commit 76a6eac

Browse files
committed
refactor(ivy): rename "blacklist" to "blocklist" (angular#28536)
PR Close angular#28536
1 parent 9ef8d2b commit 76a6eac

File tree

5 files changed

+17
-17
lines changed

5 files changed

+17
-17
lines changed

packages/platform-browser/test/dom/events/event_manager_spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ import {el} from '../../../testing/src/browser_util';
296296
expect(receivedEvents).toEqual([]);
297297
});
298298

299-
it('should run blackListedEvents handler outside of ngZone', () => {
299+
it('should run blockListedEvents handler outside of ngZone', () => {
300300
const Zone = (window as any)['Zone'];
301301
const element = el('<div><div></div></div>');
302302
getDOM().appendChild(doc.body, element);

scripts/ci/run_angular_material_unit_tests.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ cp -r ${angular_dir}/dist/packages-dist-ivy-aot/* /tmp/material2/node_modules/@a
2828
# For angular/angular, we only want to run the local tests.
2929
export TEST_PLATFORM=local
3030

31-
# Append the test blacklist into angular/material2's karma-test-shim.js.
31+
# Append the test blocklist into angular/material2's karma-test-shim.js.
3232
# This filters out known-failing tests because the goal is to prevent regressions.
33-
cat ${angular_dir}/tools/material-ci/angular_material_test_blacklist.js >> /tmp/material2/test/karma-test-shim.js
33+
cat ${angular_dir}/tools/material-ci/angular_material_test_blocklist.js >> /tmp/material2/test/karma-test-shim.js
3434

3535
# Now actually run the tests.
3636
yarn gulp test:single-run

tools/material-ci/angular_material_test_blacklist.js renamed to tools/material-ci/angular_material_test_blocklist.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,16 @@
77
*/
88

99
/**
10-
* Blacklist of unit tests from angular/material2 with ivy that are skipped when running on
11-
* angular/angular. As bugs are resolved, items should be removed from this blacklist.
10+
* Blocklist of unit tests from angular/material2 with ivy that are skipped when running on
11+
* angular/angular. As bugs are resolved, items should be removed from this blocklist.
1212
*
1313
* The `notes` section should be used to keep track of specific issues associated with the failures.
1414
*/
1515

1616
// clang-format off
1717
// tslint:disable
1818

19-
window.testBlacklist = {
19+
window.testBlocklist = {
2020
"Portals CdkPortalOutlet should load a template into the portal": {
2121
"error": "TypeError: Cannot read property 'createEmbeddedView' of undefined",
2222
"notes": "Unknown"

tools/material-ci/instructions.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
### Unit tests for Angular CDK/Material
22
The unit tests from angular/material2 run on CircleCI under the `material-unit-tests` job.
3-
Known failing tests are skipped based on the blacklist in
4-
`tools/material-ci/angular_material_test_blacklist.js`. Whenever the root cause of a known failure
3+
Known failing tests are skipped based on the blocklist in
4+
`tools/material-ci/angular_material_test_blocklist.js`. Whenever the root cause of a known failure
55
is identified, the `notes` field for the corresponding tests should be updated. Whenever a failure
6-
is resolved, the corresponding tests should be removed from the blacklist.
6+
is resolved, the corresponding tests should be removed from the blocklist.
77

88
### Debugging
99
To debug a failure, you need to work against the angular/material2 repo:
@@ -13,12 +13,12 @@ To debug a failure, you need to work against the angular/material2 repo:
1313
4. Run `scripts/ivy/install-angular.sh path/to/local/angular/repo`
1414
5. Run `gulp test`
1515

16-
### Regenerating the blacklist
17-
If a problem has been fixed, you can regenerate the blacklist by:
16+
### Regenerating the blocklist
17+
If a problem has been fixed, you can regenerate the blocklist by:
1818
1. Clone `angular/material2`
1919
2. Checkout the `ivy-2019` branch
2020
3. Run `yarn`
2121
4. Run `scripts/ivy/install-angular.sh path/to/local/angular/repo`
2222
5. Run `gulp test`. Let it finish. It will take a few minutes.
23-
6. Run `scripts/ivy/generate-blacklist.js`
24-
7. Copy the new blacklist from `dist/angular_material_test_blacklist.js`
23+
6. Run `scripts/ivy/generate-blocklist.js`
24+
7. Copy the new blocklist from `dist/angular_material_test_blocklist.js`

tools/tslint/rollupConfigRule.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ function _isRollupPath(path: string) {
1717
return /rollup\.config\.js$/.test(path);
1818
}
1919

20-
// Regexes to blacklist.
21-
const sourceFilePathBlacklist = [
20+
// Regexes to blocklist.
21+
const sourceFilePathBlocklist = [
2222
/\.spec\.ts$/,
2323
/_spec\.ts$/,
2424
/_perf\.ts$/,
@@ -62,7 +62,7 @@ const packageScopedImportWhitelist: [RegExp, string[]][] = [
6262

6363
// Return true if the file should be linted.
6464
function _pathShouldBeLinted(path: string) {
65-
return /[/\\]packages[/\\]/.test(path) && sourceFilePathBlacklist.every(re => !re.test(path));
65+
return /[/\\]packages[/\\]/.test(path) && sourceFilePathBlocklist.every(re => !re.test(path));
6666
}
6767

6868

@@ -157,7 +157,7 @@ export class Rule extends AbstractRule {
157157
sourceFile, importStatement.getStart(), importStatement.getWidth(),
158158
`Import ${JSON.stringify(modulePath)} could not be found in the rollup config ` +
159159
`at path ${JSON.stringify(rollupFilePath)}.`,
160-
this.ruleName, );
160+
this.ruleName);
161161
}
162162

163163
return null;

0 commit comments

Comments
 (0)