File tree Expand file tree Collapse file tree 2 files changed +40
-0
lines changed
Expand file tree Collapse file tree 2 files changed +40
-0
lines changed Original file line number Diff line number Diff line change 5151 "test:small" : " yarn build && node lib/tests/e2e/manual-test.js --debug --package-manager=pnpm --styling=css-modules" ,
5252 "test:large" : " yarn build && node lib/tests/e2e/manual-test.js --debug --package-manager=pnpm --styling=emotion --react-hook-form --formik --prettier --formatting-pre-commit-hook --chakra --framer-motion --github-actions" ,
5353 "test:cna" : " yarn build && node lib/tests/e2e/test-cna.js" ,
54+ "test:live" : " yarn build && node lib/tests/e2e/test-live.js" ,
5455 "print:help" : " yarn build && ./bin-test/run-prod --help" ,
5556 "print:version" : " yarn build && ./bin-test/run-prod --help" ,
5657 "version" : " oclif-dev readme && git add README.md" ,
Original file line number Diff line number Diff line change 1+ import chalk from "chalk"
2+ import endent from "endent"
3+ import { v4 as uuidv4 } from "uuid"
4+ import { prettyCommand } from "../../main/helpers/pretty-command"
5+ import { runCommand } from "../../main/run-command"
6+ import { checkFormattingLintingBuild } from "./helpers/check-formatting-linting-build"
7+ import { exitWithError } from "./helpers/exit-with-error"
8+ import { logTestInfo } from "./test-logging"
9+ ; ( async ( ) => {
10+ try {
11+ const projectName = uuidv4 ( )
12+ const runDirectory = `../create-next-stack-tests/${ projectName } `
13+
14+ const command = "npx"
15+ const args = [
16+ "create-next-stack@latest" ,
17+ ...process . argv . slice ( 2 ) ,
18+ runDirectory ,
19+ ]
20+
21+ logTestInfo ( "Running command:" , prettyCommand ( command , args ) )
22+
23+ await runCommand ( command , args , { stdio : "inherit" } )
24+
25+ await checkFormattingLintingBuild ( runDirectory )
26+
27+ logTestInfo ( "" )
28+ logTestInfo ( endent `
29+ ${ chalk . green ( "Test successful!" ) }
30+
31+ To open the project in vscode, run:
32+
33+ ${ chalk . cyan ( `code ${ runDirectory } ` ) }
34+ ` )
35+ logTestInfo ( "" )
36+ } catch ( error ) {
37+ exitWithError ( error )
38+ }
39+ } ) ( )
You can’t perform that action at this time.
0 commit comments