Browse Source

Use TS_NODE_FILES instead of --files

Because --files does not work
Chocobozzz 3 years ago
parent
commit
07aea1a264
3 changed files with 4 additions and 4 deletions
  1. 2 1
      scripts/ci.sh
  2. 2 2
      server/tests/api/ci-4.sh
  3. 0 1
      tsconfig.json

+ 2 - 1
scripts/ci.sh

@@ -13,7 +13,8 @@ perl -0777 -i  -pe 's#proxy:(\n\s+)enabled: false\n\s+url: ""#proxy:$1enabled: t
 
 if [ "$1" = "misc" ]; then
     npm run build -- --light
-    mocha --timeout 5000 --exit --require ts-node/register --files --require tsconfig-paths/register --bail server/tests/client.ts \
+    TS_NODE_FILES=true mocha --timeout 5000 --exit --require ts-node/register --require tsconfig-paths/register --bail \
+        server/tests/client.ts \
         server/tests/feeds/index.ts \
         server/tests/misc-endpoints.ts \
         server/tests/helpers/index.ts \

+ 2 - 2
server/tests/api/ci-4.sh

@@ -5,6 +5,6 @@ set -eu
 redundancyFiles=$(find server/tests/api/redundancy -type f | grep -v index.ts | xargs echo)
 activitypubFiles=$(find server/tests/api/activitypub -type f | grep -v index.ts | xargs echo)
 
-MOCHA_PARALLEL=true npm run mocha -- --parallel --jobs $1 --timeout 30000 --exit \
-  --require ts-node/register --files --require tsconfig-paths/register --bail \
+TS_NODE_FILES=true MOCHA_PARALLEL=true npm run mocha -- --parallel --jobs $1 --timeout 30000 --exit \
+  --require ts-node/register --require tsconfig-paths/register --bail \
   $redundancyFiles $activitypubFiles

+ 0 - 1
tsconfig.json

@@ -28,7 +28,6 @@
       "@shared/*": [ "shared/*" ]
     }
   },
-  "include": [ "." ],
   "exclude": [
     "server/tools/",
     "node_modules",