Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions integrationTests/conditions/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ for (const { version, moduleSync } of nodeTests) {

console.log('Testing on bun (moduleSync: true) ...');
childProcess.execSync(
`docker run --rm --volume "$PWD":/usr/src/app -w /usr/src/app --env MODULE_SYNC=true oven/bun:alpine bun ./check.mjs`,
`docker run --rm --volume "$PWD":/usr/src/app -w /usr/src/app --env MODULE_SYNC=true oven/bun:"$BUN_VERSION"-slim bun ./check.mjs`,
{ stdio: 'inherit' },
);

console.log('Testing on deno (moduleSync: false) ...');
childProcess.execSync(
`docker run --rm --volume "$PWD":/usr/src/app -w /usr/src/app --env MODULE_SYNC=false denoland/deno:alpine-2.4.1 deno run --allow-read --allow-env ./check.mjs`,
`docker run --rm --volume "$PWD":/usr/src/app -w /usr/src/app --env MODULE_SYNC=false denoland/deno:alpine-"$DENO_VERSION" deno run --allow-read --allow-env ./check.mjs`,
{ stdio: 'inherit' },
);
2 changes: 1 addition & 1 deletion integrationTests/dev-bun/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"description": "graphql-js development mode should work with Bun",
"private": true,
"scripts": {
"test": "docker run --rm --volume \"$PWD:/usr/src/app\" -w /usr/src/app oven/bun:1.2.18-slim bun test.js"
"test": "docker run --rm --volume \"$PWD\":/usr/src/app -w /usr/src/app oven/bun:\"$BUN_VERSION\"-slim bun test.js"
},
"dependencies": {
"graphql": "file:../graphql.tgz"
Expand Down
2 changes: 1 addition & 1 deletion integrationTests/dev-deno/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"description": "graphql-js development mode should work with Deno",
"private": true,
"scripts": {
"test": "docker run --rm --volume \"$PWD:/usr/src/app\" -w /usr/src/app denoland/deno:alpine-2.4.1 deno run --allow-env=NODE_ENV test.js"
"test": "docker run --rm --volume \"$PWD\":/usr/src/app -w /usr/src/app denoland/deno:alpine-\"$DENO_VERSION\" deno run --allow-env=NODE_ENV test.js"
},
"dependencies": {
"graphql": "file:../graphql.tgz"
Expand Down
2 changes: 1 addition & 1 deletion integrationTests/prod-bun/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"description": "graphql-js production mode should work with Bun",
"private": true,
"scripts": {
"test": "docker run --rm --volume \"$PWD:/usr/src/app\" -w /usr/src/app oven/bun:1.2.18-slim bun --define process.env.NODE_ENV='\"production\"' test.js"
"test": "docker run --rm --volume \"$PWD\":/usr/src/app -w /usr/src/app oven/bun:\"$BUN_VERSION\"-slim bun --define process.env.NODE_ENV='\"production\"' test.js"
},
"dependencies": {
"graphql": "file:../graphql.tgz"
Expand Down
2 changes: 1 addition & 1 deletion integrationTests/prod-deno/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"description": "graphql-js production mode should work with Deno",
"private": true,
"scripts": {
"test": "docker run --rm --volume \"$PWD:/usr/src/app\" -w /usr/src/app denoland/deno:alpine-2.4.1 deno run --allow-env --preload env-shim.js test.js"
"test": "docker run --rm --volume \"$PWD\":/usr/src/app -w /usr/src/app denoland/deno:alpine-\"$DENO_VERSION\" deno run --allow-env --preload env-shim.js test.js"
},
"dependencies": {
"graphql": "file:../graphql.tgz"
Expand Down
2 changes: 1 addition & 1 deletion integrationTests/ts/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ for (const version of tsVersions) {

console.log('Testing on deno ...');
childProcess.execSync(
`docker run --rm --volume "$PWD":/usr/src/app -w /usr/src/app denoland/deno:alpine-2.4.1 deno check`,
`docker run --rm --volume "$PWD":/usr/src/app -w /usr/src/app denoland/deno:alpine-"$DENO_VERSION" deno check`,
{ stdio: 'inherit' },
);

Expand Down
13 changes: 12 additions & 1 deletion resources/integration-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ import { describe, it } from 'mocha';

import { localRepoPath, makeTmpDir, npm, readPackageJSON } from './utils.js';

const BUN_VERSION = '1.2.18';
const DENO_VERSION = '2.4.1';

describe('Integration Tests', () => {
const { tmpDirPath } = makeTmpDir('graphql-js-integrationTmp');
fs.cpSync(localRepoPath('integrationTests'), tmpDirPath(), {
Expand Down Expand Up @@ -31,7 +34,15 @@ describe('Integration Tests', () => {
it(packageJSON.description, () => {
// TODO: figure out a way to run it with --ignore-scripts
npm({ cwd: projectPath, quiet: true }).install();
npm({ cwd: projectPath, quiet: true }).run('test');
npm({
cwd: projectPath,
quiet: true,
env: {
...process.env,
BUN_VERSION,
DENO_VERSION,
},
}).run('test');
}).timeout(120000);
}

Expand Down
Loading