Skip to content

Commit

Permalink
docs(ivy): add Ivy as a recognized label (angular#21428)
Browse files Browse the repository at this point in the history
PR Close angular#21428
  • Loading branch information
mhevery authored and leo6104 committed Mar 25, 2018
1 parent 827c4b9 commit efa5e6b
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ jobs:
# Use bazel query so that we explicitly ask for all buildable targets to be built as well
# This avoids waiting for a build command to finish before running the first test
# See https://github.com/bazelbuild/bazel/issues/4257
- run: bazel query --output=label '//modules/... union //packages/... union @angular//...' | xargs bazel test --config=ci
- run: bazel query --output=label '//modules/... union //packages/... union //tools/... union @angular//...' | xargs bazel test --config=ci

- save_cache:
key: *cache_key
Expand Down
1 change: 1 addition & 0 deletions docs/TRIAGE_AND_LABELS.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ The components have a clear piece of source code associated with it within the `
* `comp: common/http` - this includes core components / pipes
* `comp: core & compiler` - because core, compiler, compiler-cli and
browser-platforms are very intertwined, we will be treating them as one
* `comp: ivy` - a subset of core representing the new Ivy renderer.
* `comp: forms`
* `comp: http`
* `comp: i18n`
Expand Down
6 changes: 6 additions & 0 deletions tools/validate-commit-message/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
load("@build_bazel_rules_nodejs//:defs.bzl", "jasmine_node_test")

jasmine_node_test(
name = "validate-commit-message",
srcs = glob(["*.js"]),
)
1 change: 1 addition & 0 deletions tools/validate-commit-message/commit-message.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"core",
"forms",
"http",
"ivy",
"language-service",
"platform-browser",
"platform-browser-dynamic",
Expand Down
2 changes: 2 additions & 0 deletions tools/validate-commit-message/validate-commit-message.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,5 @@ module.exports = function(commitSubject) {
function error(errorMessage, commitMessage) {
console.error(`INVALID COMMIT MSG: "${commitMessage}"\n => ERROR: ${errorMessage}`);
}

module.exports.config = config;
17 changes: 9 additions & 8 deletions tools/validate-commit-message/validate-commit-message.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

describe('validate-commit-message.js', function() {
var validateMessage = require('./validate-commit-message');
var SCOPES = validateMessage.config.scopes.join(', ');
var errors = [];
var logs = [];

Expand Down Expand Up @@ -51,22 +52,22 @@ describe('validate-commit-message.js', function() {
expect(validateMessage('refactor(docs): something')).toBe(INVALID);
['INVALID COMMIT MSG: "fix(Compiler): something"\n' +
' => ERROR: "Compiler" is not an allowed scope.\n' +
' => SCOPES: aio, animations, bazel, benchpress, common, compiler, compiler-cli, core, forms, http, language-service, platform-browser, platform-browser-dynamic, platform-server, platform-webworker, platform-webworker-dynamic, router, service-worker, upgrade, packaging, changelog',
' => SCOPES: ' + SCOPES,
'INVALID COMMIT MSG: "feat(bah): something"\n' +
' => ERROR: "bah" is not an allowed scope.\n' +
' => SCOPES: aio, animations, bazel, benchpress, common, compiler, compiler-cli, core, forms, http, language-service, platform-browser, platform-browser-dynamic, platform-server, platform-webworker, platform-webworker-dynamic, router, service-worker, upgrade, packaging, changelog',
' => SCOPES: ' + SCOPES,
'INVALID COMMIT MSG: "style(webworker): something"\n' +
' => ERROR: "webworker" is not an allowed scope.\n' +
' => SCOPES: aio, animations, bazel, benchpress, common, compiler, compiler-cli, core, forms, http, language-service, platform-browser, platform-browser-dynamic, platform-server, platform-webworker, platform-webworker-dynamic, router, service-worker, upgrade, packaging, changelog',
' => SCOPES: ' + SCOPES,
'INVALID COMMIT MSG: "refactor(security): something"\n' +
' => ERROR: "security" is not an allowed scope.\n' +
' => SCOPES: aio, animations, bazel, benchpress, common, compiler, compiler-cli, core, forms, http, language-service, platform-browser, platform-browser-dynamic, platform-server, platform-webworker, platform-webworker-dynamic, router, service-worker, upgrade, packaging, changelog',
' => SCOPES: ' + SCOPES,
'INVALID COMMIT MSG: "refactor(docs): something"\n' +
' => ERROR: "docs" is not an allowed scope.\n' +
' => SCOPES: aio, animations, bazel, benchpress, common, compiler, compiler-cli, core, forms, http, language-service, platform-browser, platform-browser-dynamic, platform-server, platform-webworker, platform-webworker-dynamic, router, service-worker, upgrade, packaging, changelog']
.forEach((expectedErrorMessage, index) => {
expect(expectedErrorMessage).toEqual(errors[index]);
});
' => SCOPES: ' + SCOPES,
].forEach((expectedErrorMessage, index) => {
expect(expectedErrorMessage).toEqual(errors[index]);
});
expect(validateMessage('release(angular): something')).toBe(INVALID);
});

Expand Down

0 comments on commit efa5e6b

Please sign in to comment.