diff --git a/.circleci/config.yml b/.circleci/config.yml index cd83ede4b..7fc6f2dfe 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -91,7 +91,6 @@ jobs: - attach_workspace: at: "." - - run: npm i -g ts-node - run: npm run test:end-to-end test-unit: @@ -144,6 +143,10 @@ workflows: - prettier: requires: - build + - test-end-to-end: + requires: + - build + - tsc - test-unit: requires: - build diff --git a/docs/Testing.md b/docs/Testing.md index 3b28d335e..b75bd5fa6 100644 --- a/docs/Testing.md +++ b/docs/Testing.md @@ -42,3 +42,5 @@ Within each directory, a test suite will execute `bin/tslint-to-eslint` and vali Use `npm run test:end-to-end:accept` to overwrite the expected contents of files with what is actually written. These behave similarly to updating snapshots in snapshot testing. + +> Note: these end-to-end tests use the compiled result of `npm run tsc`, so if you update source code, re-run `npm run tsc` before `npm run test:end-to-end`. diff --git a/test/createTests.ts b/test/createTests.ts index 65e2df159..8fa598c31 100644 --- a/test/createTests.ts +++ b/test/createTests.ts @@ -36,7 +36,7 @@ export const createTests = ( const act = async (testArgs: string[]) => { try { - return await exec(`ts-node ${binFile} ${testArgs.join(" ")}`, { + return await exec(`node ${binFile} ${testArgs.join(" ")}`, { cwd, }); } catch (error) {