Skip to content

Commit aa354cf

Browse files
committed
base port?
1 parent d988875 commit aa354cf

File tree

13 files changed

+21
-14
lines changed

13 files changed

+21
-14
lines changed

packages/e2e-tests/lib/buildApp.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ export async function buildApp(appDir: string, recipeInstance: RecipeInstance, e
3737
env: {
3838
...process.env,
3939
...env,
40-
4140
YARN_CACHE_FOLDER: tempYarnCache, // Use a separate yarn cache for each build commmand because multiple yarn commands running at the same time may corrupt the cache
4241
} as unknown as NodeJS.ProcessEnv,
4342
});

packages/e2e-tests/lib/runAllTestApps.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ export async function runAllTestApps(
1111

1212
const recipeInstances = constructRecipeInstances(recipePaths);
1313

14-
console.log(JSON.stringify(recipeInstances));
15-
1614
const results = await shardPromises(
1715
recipeInstances,
1816
recipeInstance => buildAndTestApp(recipeInstance, envVarsToInject),

packages/e2e-tests/run.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ async function run(): Promise<void> {
1818
const envVarsToInject = {
1919
REACT_APP_E2E_TEST_DSN: process.env.E2E_TEST_DSN,
2020
NEXT_PUBLIC_E2E_TEST_DSN: process.env.E2E_TEST_DSN,
21+
BASE_PORT: '27496',
2122
};
2223

2324
try {

packages/e2e-tests/test-applications/create-next-app/playwright.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ const config: PlaywrightTestConfig = {
6060
/* Run your local dev server before starting the tests */
6161
webServer: {
6262
command: process.env.TEST_MODE === 'prod' ? 'yarn start' : 'yarn dev',
63-
port: 3000 + Number(process.env.PORT_MODULO ?? 0),
63+
port: Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0),
6464
},
6565
};
6666

packages/e2e-tests/test-applications/nextjs-app-dir/playwright.config.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ if (!testEnv) {
77
throw new Error('No test env defined');
88
}
99

10-
const port = 3000 + Number(process.env.PORT_MODULO ?? 0);
10+
const port = Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0);
1111

1212
/**
1313
* See https://playwright.dev/docs/test-configuration.
@@ -60,7 +60,10 @@ const config: PlaywrightTestConfig = {
6060
},
6161
{
6262
command: 'yarn ts-node-script start-event-proxy.ts',
63-
port: 3000 + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0),
63+
port:
64+
Number(process.env.BASE_PORT ?? 5698) +
65+
Number(process.env.PORT_MODULO ?? 0) +
66+
Number(process.env.PORT_GAP ?? 0),
6467
},
6568
],
6669
};

packages/e2e-tests/test-applications/nextjs-app-dir/sentry.client.config.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ import * as Sentry from '@sentry/nextjs';
22

33
Sentry.init({
44
dsn: process.env.NEXT_PUBLIC_E2E_TEST_DSN,
5-
tunnel: `http://localhost:${3000 + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0)}/`, // proxy server
5+
tunnel: `http://localhost:${
6+
Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0)
7+
}/`, // proxy server
68
tracesSampleRate: 1.0,
79
});

packages/e2e-tests/test-applications/nextjs-app-dir/sentry.edge.config.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ import * as Sentry from '@sentry/nextjs';
22

33
Sentry.init({
44
dsn: process.env.NEXT_PUBLIC_E2E_TEST_DSN,
5-
tunnel: `http://localhost:${3000 + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0)}/`, // proxy server
5+
tunnel: `http://localhost:${
6+
Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0)
7+
}/`, // proxy server
68
tracesSampleRate: 1.0,
79
});

packages/e2e-tests/test-applications/nextjs-app-dir/sentry.server.config.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ import * as Sentry from '@sentry/nextjs';
22

33
Sentry.init({
44
dsn: process.env.NEXT_PUBLIC_E2E_TEST_DSN,
5-
tunnel: `http://localhost:${3000 + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0)}/`, // proxy server
5+
tunnel: `http://localhost:${
6+
Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0)
7+
}/`, // proxy server
68
tracesSampleRate: 1.0,
79
});
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { startEventProxyServer } from '../../test-utils/event-proxy-server';
22

33
startEventProxyServer({
4-
port: 3000 + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0),
4+
port: Number(process.env.BASE_PORT ?? 0) + Number(process.env.PORT_MODULO ?? 0) + Number(process.env.PORT_GAP ?? 0),
55
proxyServerName: 'nextjs-13-app-dir',
66
});

packages/e2e-tests/test-applications/node-express-app/playwright.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ const config: PlaywrightTestConfig = {
5858
/* Run your local dev server before starting the tests */
5959
webServer: {
6060
command: 'yarn start',
61-
port: 3000 + Number(process.env.PORT_MODULO ?? 0),
61+
port: Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0),
6262
},
6363
};
6464

packages/e2e-tests/test-applications/node-express-app/src/app.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Sentry.init({
1717
});
1818

1919
const app = express();
20-
const port = 3000 + Number(process.env.PORT_MODULO ?? 0);
20+
const port = Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0);
2121

2222
app.use(Sentry.Handlers.requestHandler());
2323
app.use(Sentry.Handlers.tracingHandler());

packages/e2e-tests/test-applications/standard-frontend-react-tracing-import/playwright.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ const config: PlaywrightTestConfig = {
6060
/* Run your local dev server before starting the tests */
6161
webServer: {
6262
command: 'yarn start',
63-
port: 3000 + Number(process.env.PORT_MODULO ?? 0),
63+
port: Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0),
6464
},
6565
};
6666

packages/e2e-tests/test-applications/standard-frontend-react/playwright.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ const config: PlaywrightTestConfig = {
6060
/* Run your local dev server before starting the tests */
6161
webServer: {
6262
command: 'yarn start',
63-
port: 3000 + Number(process.env.PORT_MODULO ?? 0),
63+
port: Number(process.env.BASE_PORT ?? 5698) + Number(process.env.PORT_MODULO ?? 0),
6464
},
6565
};
6666

0 commit comments

Comments
 (0)