Skip to content

Commit

Permalink
chore: move CI tests to test:ci (#1368)
Browse files Browse the repository at this point in the history
  • Loading branch information
haythemsellami authored Sep 4, 2023
1 parent 111de0c commit d52e7c7
Show file tree
Hide file tree
Showing 25 changed files with 46 additions and 24 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,4 @@ jobs:
env:
DATABASE_URL: "postgres://postgres@localhost:5432/postgres"
working-directory: ./e2e/packages/sync-test
run: pnpm test
run: pnpm test:ci
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- name: Run tests
env:
DATABASE_URL: "postgres://postgres@localhost:5432/postgres"
run: pnpm test
run: pnpm test:ci

- name: Generate gas reports
run: pnpm gas-report
Expand Down
3 changes: 2 additions & 1 deletion e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
"build": "pnpm recursive run build",
"clean": "pnpm recursive run clean",
"playwright-install": "pnpx [email protected] install --with-deps chromium",
"test": "pnpm recursive run test"
"test": "pnpm recursive run test",
"test:ci": "pnpm run test"
},
"devDependencies": {
"@playwright/test": "1.35.1"
Expand Down
3 changes: 2 additions & 1 deletion e2e/packages/contracts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
"clean:mud": "rimraf src/codegen",
"clean:typechain": "rimraf types",
"deploy:local": "mud deploy",
"test": "mud test"
"test": "mud test",
"test:ci": "pnpm run test"
},
"devDependencies": {
"@latticexyz/cli": "link:../../../packages/cli",
Expand Down
3 changes: 2 additions & 1 deletion e2e/packages/sync-test/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
"private": true,
"license": "MIT",
"scripts": {
"test": "vitest --run"
"test": "vitest --run",
"test:ci": "pnpm run test"
},
"devDependencies": {
"@latticexyz/cli": "link:../../../packages/cli",
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@
"release:publish": "pnpm install && pnpm build && changeset publish",
"release:version": "changeset version && pnpm install --lockfile-only && pnpx [email protected] scripts/changelog.ts",
"sort-package-json": "npx sort-package-json package.json 'packages/*/package.json' 'templates/*/package.json' 'templates/*/packages/*/package.json' 'examples/*/package.json' 'examples/*/packages/*/package.json' 'e2e/*/package.json' 'e2e/*/packages/*/package.json' 'docs/package.json'",
"test": "pnpm recursive run test"
"test": "pnpm recursive run test",
"test:ci": "pnpm recursive run test:ci"
},
"lint-staged": {
"*.{ts,tsx}": "eslint --cache --fix",
Expand Down
3 changes: 2 additions & 1 deletion packages/block-logs-stream/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"lint": "eslint .",
"test": "vitest typecheck --run --passWithNoTests && vitest --run --passWithNoTests"
"test": "vitest typecheck --run --passWithNoTests && vitest --run --passWithNoTests",
"test:ci": "pnpm run test"
},
"dependencies": {
"@latticexyz/common": "workspace:*",
Expand Down
3 changes: 2 additions & 1 deletion packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"lint": "eslint . --ext .ts",
"test": "tsc --noEmit && forge test"
"test": "tsc --noEmit && forge test",
"test:ci": "pnpm run test"
},
"dependencies": {
"@ethersproject/abi": "^5.7.0",
Expand Down
3 changes: 2 additions & 1 deletion packages/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@
"clean": "pnpm run clean:js",
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"test": "vitest typecheck --run --passWithNoTests && vitest --run"
"test": "vitest typecheck --run --passWithNoTests && vitest --run",
"test:ci": "pnpm run test"
},
"dependencies": {
"@latticexyz/schema-type": "workspace:*",
Expand Down
3 changes: 2 additions & 1 deletion packages/config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@
"clean": "pnpm run clean:js",
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"test": "tsc --noEmit"
"test": "tsc --noEmit",
"test:ci": "pnpm run test"
},
"dependencies": {
"@latticexyz/common": "workspace:*",
Expand Down
1 change: 1 addition & 0 deletions packages/create-mud/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"dev": "tsup --watch",
"prepublishOnly": "npm run clean && npm run build",
"test": "pnpm run test:vanilla && pnpm run test:react && pnpm run test:phaser && pnpm run test:threejs",
"test:ci": "pnpm run test",
"test:phaser": "dist/cli.js test-project --template phaser && rimraf test-project",
"test:react": "dist/cli.js test-project --template react && rimraf test-project",
"test:threejs": "dist/cli.js test-project --template threejs && rimraf test-project",
Expand Down
3 changes: 2 additions & 1 deletion packages/dev-tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
"clean": "pnpm run clean:js",
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"test": "tsc --noEmit"
"test": "tsc --noEmit",
"test:ci": "pnpm run test"
},
"dependencies": {
"@latticexyz/common": "workspace:*",
Expand Down
3 changes: 2 additions & 1 deletion packages/gas-report/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
"build": "tsup",
"clean": "rimraf dist",
"dev": "tsup --watch",
"test": "vitest typecheck --run --passWithNoTests && vitest --run --passWithNoTests && forge test"
"test": "vitest typecheck --run --passWithNoTests && vitest --run --passWithNoTests && forge test",
"test:ci": "pnpm run test"
},
"dependencies": {
"chalk": "^5.3.0",
Expand Down
3 changes: 2 additions & 1 deletion packages/noise/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
"clean:wasm": "rimraf build",
"dev": "tsup --watch",
"start": "npx serve .",
"test": "forge test && tsc --noEmit"
"test": "forge test && tsc --noEmit",
"test:ci": "pnpm run test"
},
"dependencies": {
"abdk-libraries-solidity": "^3.0.0",
Expand Down
3 changes: 2 additions & 1 deletion packages/phaserx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"lint": "eslint . --ext .ts",
"test": "tsc --noEmit"
"test": "tsc --noEmit",
"test:ci": "pnpm run test"
},
"dependencies": {
"@latticexyz/utils": "workspace:*",
Expand Down
3 changes: 2 additions & 1 deletion packages/protocol-parser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"lint": "eslint .",
"test": "vitest typecheck --run && vitest --run"
"test": "vitest typecheck --run && vitest --run",
"test:ci": "pnpm run test"
},
"dependencies": {
"@latticexyz/common": "workspace:*",
Expand Down
3 changes: 2 additions & 1 deletion packages/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
"clean": "pnpm run clean:js",
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"test": "tsc --noEmit && vitest --run"
"test": "tsc --noEmit && vitest --run",
"test:ci": "pnpm run test"
},
"dependencies": {
"@latticexyz/recs": "workspace:*",
Expand Down
3 changes: 2 additions & 1 deletion packages/recs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"lint": "eslint . --ext .ts",
"test": "tsc --noEmit && jest"
"test": "tsc --noEmit && jest",
"test:ci": "pnpm run test"
},
"dependencies": {
"@latticexyz/schema-type": "workspace:*",
Expand Down
3 changes: 2 additions & 1 deletion packages/schema-type/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@
"clean:js": "rimraf dist/typescript",
"dev": "tsup --watch",
"gas-report": "mud-gas-report --save gas-report.json",
"test": "vitest typecheck --run && vitest --run && forge test"
"test": "vitest typecheck --run && vitest --run && forge test",
"test:ci": "pnpm run test"
},
"dependencies": {
"abitype": "0.9.3",
Expand Down
1 change: 1 addition & 0 deletions packages/services/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
"build:protobuf": "make protoc-ts && prettier --write protobuf/ts/**/*.ts",
"dev": "tsup --watch",
"test": "pnpm run test:go",
"test:ci": "pnpm run test",
"test:go": "go test -v ./..."
},
"dependencies": {
Expand Down
3 changes: 2 additions & 1 deletion packages/store-indexer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@
"start:sqlite:local": "SQLITE_FILENAME=anvil.db CHAIN_ID=31337 pnpm start:sqlite",
"start:sqlite:testnet": "SQLITE_FILENAME=testnet.db CHAIN_ID=4242 START_BLOCK=19037160 pnpm start:sqlite",
"start:sqlite:testnet2": "SQLITE_FILENAME=testnet2.db CHAIN_ID=4243 pnpm start:sqlite",
"test": "tsc --noEmit --skipLibCheck"
"test": "tsc --noEmit --skipLibCheck",
"test:ci": "pnpm run test"
},
"dependencies": {
"@fastify/cors": "^8.3.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/store-sync/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"lint": "eslint .",
"test": "vitest --run",
"test:local": "DATABASE_URL=http://127.0.0.1:5432/postgres vitest"
"test": "DATABASE_URL=http://127.0.0.1:5432/postgres vitest",
"test:ci": "vitest --run"
},
"dependencies": {
"@latticexyz/block-logs-stream": "workspace:*",
Expand Down
3 changes: 2 additions & 1 deletion packages/store/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@
"dev": "tsup --watch",
"gas-report": "mud-gas-report --save gas-report.json",
"lint": "solhint --config ./.solhint.json 'src/**/*.sol'",
"test": "vitest typecheck --run && vitest --run --passWithNoTests && forge test"
"test": "vitest typecheck --run && vitest --run --passWithNoTests && forge test",
"test:ci": "pnpm run test"
},
"dependencies": {
"@ethersproject/abi": "^5.7.0",
Expand Down
3 changes: 2 additions & 1 deletion packages/utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
"clean:js": "rimraf dist",
"dev": "tsup --watch",
"lint": "eslint . --ext .ts",
"test": "tsc --noEmit && jest"
"test": "tsc --noEmit && jest",
"test:ci": "pnpm run test"
},
"dependencies": {
"ethers": "^5.7.2",
Expand Down
3 changes: 2 additions & 1 deletion packages/world/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@
"dev": "tsup --watch",
"gas-report": "mud-gas-report --save gas-report.json",
"lint": "solhint --config ./.solhint.json 'src/**/*.sol'",
"test": "tsc --noEmit && vitest --run && forge test"
"test": "tsc --noEmit && vitest --run && forge test",
"test:ci": "pnpm run test"
},
"dependencies": {
"@ethersproject/abi": "^5.7.0",
Expand Down

0 comments on commit d52e7c7

Please sign in to comment.