From bfa20e11a68151e2bc08431c634c85d9c0edc697 Mon Sep 17 00:00:00 2001 From: JoostK Date: Mon, 16 Nov 2020 12:57:18 +0100 Subject: [PATCH] test(compiler-cli): fix documentation and JSON schema references in compliance tests (#39707) The JSON schema reference was off-by-one, preventing IDEs from finding the file and offering suggestions and documentation. Additionally the name of the golden file was slightly off. PR Close #39707 --- packages/compiler-cli/test/compliance/README.md | 6 +++--- .../r3_compiler_compliance/elements/TEST_CASES.json | 2 +- .../r3_view_compiler/interpolations/TEST_CASES.json | 2 +- .../directives/matching/TEST_CASES.json | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/compiler-cli/test/compliance/README.md b/packages/compiler-cli/test/compliance/README.md index 5315510084..25ed1621d0 100644 --- a/packages/compiler-cli/test/compliance/README.md +++ b/packages/compiler-cli/test/compliance/README.md @@ -122,8 +122,8 @@ test-cases, which each contain multiple input files, there will only be one gold The golden file is generated by the tooling and should not be modified manually. -When you first create a test-case, with an empty `PARTIAL_GOLDEN.js` file, or a change is made to -the generated partial output, we must update the `PARTIAL_GOLDEN.js` file. +When you first create a test-case, with an empty `GOLDEN_PARTIAL.js` file, or a change is made to +the generated partial output, we must update the `GOLDEN_PARTIAL.js` file. This is done by running a specific bazel rule of the form: @@ -132,7 +132,7 @@ bazel run //packages/compiler-cli/test/compliance/test_cases: ``` where to replace `` with the path (relative to `test_cases`) of the directory -that contains the `PARTIAL_GOLDEN.js` to update. +that contains the `GOLDEN_PARTIAL.js` to update. ## Debugging test-cases diff --git a/packages/compiler-cli/test/compliance/test_cases/r3_compiler_compliance/elements/TEST_CASES.json b/packages/compiler-cli/test/compliance/test_cases/r3_compiler_compliance/elements/TEST_CASES.json index ad75a49600..b5932cf87d 100644 --- a/packages/compiler-cli/test/compliance/test_cases/r3_compiler_compliance/elements/TEST_CASES.json +++ b/packages/compiler-cli/test/compliance/test_cases/r3_compiler_compliance/elements/TEST_CASES.json @@ -1,5 +1,5 @@ { - "$schema": "../test_case_schema.json", + "$schema": "../../test_case_schema.json", "cases": [ { "description": "should handle SVG", diff --git a/packages/compiler-cli/test/compliance/test_cases/r3_view_compiler/interpolations/TEST_CASES.json b/packages/compiler-cli/test/compliance/test_cases/r3_view_compiler/interpolations/TEST_CASES.json index a238c8f973..40fe28787d 100644 --- a/packages/compiler-cli/test/compliance/test_cases/r3_view_compiler/interpolations/TEST_CASES.json +++ b/packages/compiler-cli/test/compliance/test_cases/r3_view_compiler/interpolations/TEST_CASES.json @@ -1,5 +1,5 @@ { - "$schema": "../test_case_schema.json", + "$schema": "../../test_case_schema.json", "cases": [ { "description": "should generate a correct call to `ɵɵtextInterpolateV()` with more than 8 interpolations", diff --git a/packages/compiler-cli/test/compliance/test_cases/r3_view_compiler_directives/directives/matching/TEST_CASES.json b/packages/compiler-cli/test/compliance/test_cases/r3_view_compiler_directives/directives/matching/TEST_CASES.json index a693113109..6ccf180b44 100644 --- a/packages/compiler-cli/test/compliance/test_cases/r3_view_compiler_directives/directives/matching/TEST_CASES.json +++ b/packages/compiler-cli/test/compliance/test_cases/r3_view_compiler_directives/directives/matching/TEST_CASES.json @@ -1,5 +1,5 @@ { - "$schema": "../../test_case_schema.json", + "$schema": "../../../test_case_schema.json", "cases": [ { "description": "should not match directives on i18n attribute",