Skip to content

Commit 0198f12

Browse files
committed
feat: playwright component testing
1 parent ca59ce9 commit 0198f12

File tree

9 files changed

+510
-1
lines changed

9 files changed

+510
-1
lines changed

index.ts

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,9 @@ async function init() {
228228
},
229229
{
230230
title: 'Playwright',
231+
description: answers.needsVitest
232+
? undefined
233+
: 'also supports unit testing with Playwright Component Testing',
231234
value: 'playwright'
232235
}
233236
]
@@ -284,6 +287,7 @@ async function init() {
284287
const needsCypress = argv.cypress || argv.tests || needsE2eTesting === 'cypress'
285288
const needsCypressCT = needsCypress && !needsVitest
286289
const needsPlaywright = argv.playwright || needsE2eTesting === 'playwright'
290+
const needsPlaywrightCT = needsPlaywright && !needsVitest
287291

288292
const root = path.join(cwd, targetDir)
289293

@@ -333,6 +337,9 @@ async function init() {
333337
if (needsPlaywright) {
334338
render('config/playwright')
335339
}
340+
if (needsPlaywrightCT) {
341+
render('config/playwright-ct')
342+
}
336343
if (needsTypeScript) {
337344
render('config/typescript')
338345

@@ -447,7 +454,9 @@ async function init() {
447454
console.log(`\nDone. Now run:\n`)
448455
if (root !== cwd) {
449456
const cdProjectName = path.relative(cwd, root)
450-
console.log(` ${bold(green(`cd ${cdProjectName.includes(' ') ? `"${cdProjectName}"` : cdProjectName}`))}`)
457+
console.log(
458+
` ${bold(green(`cd ${cdProjectName.includes(' ') ? `"${cdProjectName}"` : cdProjectName}`))}`
459+
)
451460
}
452461
console.log(` ${bold(green(getCommand(packageManager, 'install')))}`)
453462
if (needsPrettier) {

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy