Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: remove disableTypeScriptVersionCheck from tests setup #22341

Merged
merged 1 commit into from
Dec 11, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
11 changes: 1 addition & 10 deletions tests/legacy-cli/e2e/setup/500-create-project.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { setRegistry as setNPMConfigRegistry } from '../utils/packages';
import { ng, npm } from '../utils/process';
import { prepareProjectForE2e, updateJsonFile } from '../utils/project';

export default async function() {
export default async function () {
const argv = getGlobalVariable('argv');

if (argv.noproject) {
Expand All @@ -28,15 +28,6 @@ export default async function() {
await expectFileToExist(join(process.cwd(), 'test-project'));
process.chdir('./test-project');

// Disable the TS version check to make TS updates easier.
// Only VE does it, but on Ivy the i18n extraction uses VE.
await updateJsonFile('tsconfig.json', config => {
if (!config.angularCompilerOptions) {
config.angularCompilerOptions = {};
}
config.angularCompilerOptions.disableTypeScriptVersionCheck = true;
});

// If on CI, the user configuration set above will handle project usage
if (!isCI) {
// Ensure local test registry is used inside a project
Expand Down
8 changes: 2 additions & 6 deletions tests/legacy-cli/e2e/tests/i18n/ivy-localize-es2015.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,14 @@ import { updateJsonFile } from '../../utils/project';
import { expectToFail } from '../../utils/utils';
import { externalServer, langTranslations, setupI18nConfig } from './setup';

export default async function() {
export default async function () {
// Setup i18n tests and config.
await setupI18nConfig();

// Ensure a es2017 build is used.
await writeFile('.browserslistrc', 'Chrome 65');
await updateJsonFile('tsconfig.json', config => {
await updateJsonFile('tsconfig.json', (config) => {
config.compilerOptions.target = 'es2017';
if (!config.angularCompilerOptions) {
config.angularCompilerOptions = {};
}
config.angularCompilerOptions.disableTypeScriptVersionCheck = true;
});

await ng('build', '--source-map');
Expand Down