From 627f490c745a7ec121cb5d85cf2001bb06738a77 Mon Sep 17 00:00:00 2001 From: Haoqun Jiang Date: Tue, 13 Jun 2023 15:19:40 +0800 Subject: [PATCH] fix: revert the `--tests` flag behavior Fixes #297 To avoid confusions, the `--tests` flag should include exact *one* set of test configurations. In the previous versions, it was Vitest for unit testing and Cypress for E2E testing. So for consistency, we remove the newly added Nightwatch template from it. But as we have more and more testing options, I would encourage everyone to specify the name of the testing framework they want to use, rather than use the general `--tests` flag. It would also be less prone to bugs --- index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.ts b/index.ts index 89c56028..b5fd6867 100755 --- a/index.ts +++ b/index.ts @@ -296,7 +296,7 @@ async function init() { const { needsE2eTesting } = result const needsCypress = argv.cypress || argv.tests || needsE2eTesting === 'cypress' const needsCypressCT = needsCypress && !needsVitest - const needsNightwatch = argv.nightwatch || argv.tests || needsE2eTesting === 'nightwatch' + const needsNightwatch = argv.nightwatch || needsE2eTesting === 'nightwatch' const needsNightwatchCT = needsNightwatch && !needsVitest const needsPlaywright = argv.playwright || needsE2eTesting === 'playwright' -- 2.39.5