From 4f5c611252a842f04977b6fd0759556c2d0c692d Mon Sep 17 00:00:00 2001 From: Johannes Leimer Date: Tue, 4 Jun 2024 15:48:54 +0200 Subject: [PATCH 1/2] Move files to subfolder without any changes --- {features => subfolder/features}/homepage.feature | 0 playwright.config.ts => subfolder/playwright.config.ts | 0 {steps => subfolder/steps}/fixtures.ts | 0 {steps => subfolder/steps}/index.ts | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename {features => subfolder/features}/homepage.feature (100%) rename playwright.config.ts => subfolder/playwright.config.ts (100%) rename {steps => subfolder/steps}/fixtures.ts (100%) rename {steps => subfolder/steps}/index.ts (100%) diff --git a/features/homepage.feature b/subfolder/features/homepage.feature similarity index 100% rename from features/homepage.feature rename to subfolder/features/homepage.feature diff --git a/playwright.config.ts b/subfolder/playwright.config.ts similarity index 100% rename from playwright.config.ts rename to subfolder/playwright.config.ts diff --git a/steps/fixtures.ts b/subfolder/steps/fixtures.ts similarity index 100% rename from steps/fixtures.ts rename to subfolder/steps/fixtures.ts diff --git a/steps/index.ts b/subfolder/steps/index.ts similarity index 100% rename from steps/index.ts rename to subfolder/steps/index.ts From 86eacc6acb6147f42b5de899b1bedec7eacaa19c Mon Sep 17 00:00:00 2001 From: Johannes Leimer Date: Tue, 4 Jun 2024 15:51:27 +0200 Subject: [PATCH 2/2] Adapt script paths --- .gitignore | 6 +++--- package.json | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 05863a7..343da94 100644 --- a/.gitignore +++ b/.gitignore @@ -10,9 +10,9 @@ npm-debug.log .env # tests -test-results -playwright-report -cucumber-report +subfolder/test-results +subfolder/playwright-report +subfolder/cucumber-report **/.features-gen/**/*.spec.js .nx diff --git a/package.json b/package.json index 8b69483..e4193b7 100644 --- a/package.json +++ b/package.json @@ -2,9 +2,9 @@ "name": "playwright-bdd-example", "version": "0.1.0", "scripts": { - "test": "npx bddgen && npx playwright test", - "watch:bdd": "nodemon -w ./features -w ./steps -e feature,js,ts --exec \"npx bddgen\"", - "watch:pw": "playwright test --ui", + "test": "npx bddgen --config subfolder/playwright.config.ts && npx playwright test --config subfolder/playwright.config.ts", + "watch:bdd": "nodemon -w ./subfolder/features -w ./subfolder/steps -e feature,js,ts --exec \"npx bddgen --config subfolder/playwright.config.ts\"", + "watch:pw": "playwright test --ui --config subfolder/playwright.config.ts", "watch": "run-p watch:*" }, "devDependencies": {