diff --git a/composer.json b/composer.json index 08888ec..8e3bd8b 100644 --- a/composer.json +++ b/composer.json @@ -71,13 +71,16 @@ "prepare": "@php vendor/bin/testbench package:discover --ansi", "build": "@php vendor/bin/testbench workbench:build --ansi", "dusk:install-chromedriver": "@php vendor/bin/dusk-updater detect --auto-update --ansi", - "setup-bun": [ - "cd ./workbench && npm i", - "cp ./workbench/jsconfig.json ./vendor/orchestra/testbench-core/laravel" + + "setup-workbench": [ + "cd ./workbench && npm ci", + "ln -sf $PWD/workbench/jsconfig.json ./vendor/orchestra/testbench-core/laravel/jsconfig.json", + "ln -sf $PWD/workbench/node_modules/ ./vendor/orchestra/testbench-core/laravel/node_modules", + "ln -sf $PWD/workbench/resources/js/ ./vendor/orchestra/testbench-core/laravel/resources/js" ], "serve": [ - "@setup-bun", + "@setup-workbench", "Composer\\Config::disableProcessTimeout", "@build", "@php vendor/bin/testbench serve" diff --git a/testbench.yaml b/testbench.yaml index d414d24..6fcf9e7 100644 --- a/testbench.yaml +++ b/testbench.yaml @@ -14,14 +14,4 @@ workbench: build: [] assets: [] sync: - # Link Bun binary & packages used in testing - - from: ./workbench/node_modules - to: ./vendor/orchestra/testbench-core/laravel/node_modules - - # Link local javascript resource dir - - from: ./workbench/resources/js - to: ./vendor/orchestra/testbench-core/laravel/resources/js - - # Link config - (problematic, swapped for cp in serve script) - # - from: ./workbench/jsconfig.json - # to: ./vendor/orchestra/testbench-core/laravel + # Setup done via composer script instead: composer setup-workbench diff --git a/workbench/.gitignore b/workbench/.gitignore index e69de29..3c3629e 100644 --- a/workbench/.gitignore +++ b/workbench/.gitignore @@ -0,0 +1 @@ +node_modules