mirror of
https://github.com/angular/angular-cli.git
synced 2025-05-22 15:02:11 +08:00
ci: configure bazel to ignore vite tests when using non esbuild tests
This commit configures bazel to skip adding vite tests to the webpack tests shards.
This commit is contained in:
parent
286e5d32f2
commit
5ec624e119
@ -38,6 +38,10 @@ ESBUILD_TESTS = [
|
|||||||
"tests/test/**",
|
"tests/test/**",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
WEBPACK_IGNORE_TESTS = [
|
||||||
|
"tests/vite/**",
|
||||||
|
]
|
||||||
|
|
||||||
def _to_glob(patterns):
|
def _to_glob(patterns):
|
||||||
if len(patterns) == 1:
|
if len(patterns) == 1:
|
||||||
return patterns[0]
|
return patterns[0]
|
||||||
@ -126,7 +130,7 @@ def _e2e_suite(name, runner, type, data, toolchain_name = "", toolchain = None):
|
|||||||
if type == "yarn":
|
if type == "yarn":
|
||||||
args.append("--yarn")
|
args.append("--yarn")
|
||||||
tests = YARN_TESTS
|
tests = YARN_TESTS
|
||||||
ignore = BROWSER_TESTS
|
ignore = BROWSER_TESTS + WEBPACK_IGNORE_TESTS
|
||||||
elif type == "esbuild":
|
elif type == "esbuild":
|
||||||
args.append("--esbuild")
|
args.append("--esbuild")
|
||||||
tests = ESBUILD_TESTS
|
tests = ESBUILD_TESTS
|
||||||
@ -137,7 +141,7 @@ def _e2e_suite(name, runner, type, data, toolchain_name = "", toolchain = None):
|
|||||||
ignore = None
|
ignore = None
|
||||||
elif type == "npm":
|
elif type == "npm":
|
||||||
tests = None
|
tests = None
|
||||||
ignore = BROWSER_TESTS
|
ignore = BROWSER_TESTS + WEBPACK_IGNORE_TESTS
|
||||||
|
|
||||||
# Standard e2e tests
|
# Standard e2e tests
|
||||||
_e2e_tests(
|
_e2e_tests(
|
||||||
|
@ -2,14 +2,8 @@ import { setTimeout } from 'node:timers/promises';
|
|||||||
import assert from 'node:assert';
|
import assert from 'node:assert';
|
||||||
import { findFreePort } from '../../utils/network';
|
import { findFreePort } from '../../utils/network';
|
||||||
import { execAndWaitForOutputToMatch, killAllProcesses, ng } from '../../utils/process';
|
import { execAndWaitForOutputToMatch, killAllProcesses, ng } from '../../utils/process';
|
||||||
import { getGlobalVariable } from '../../utils/env';
|
|
||||||
|
|
||||||
export default async function () {
|
export default async function () {
|
||||||
const useWebpackBuilder = !getGlobalVariable('argv')['esbuild'];
|
|
||||||
if (useWebpackBuilder) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
await ng('cache', 'clean');
|
await ng('cache', 'clean');
|
||||||
await ng('cache', 'on');
|
await ng('cache', 'on');
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user