Skip to content

Commit 9ff95b7

Browse files
author
Reno
authored
test: Create ingestion verification test cases with parallel processing (#138)
1 parent 5bb69d7 commit 9ff95b7

File tree

6 files changed

+8961
-6832
lines changed

6 files changed

+8961
-6832
lines changed

package-lock.json

Lines changed: 8607 additions & 6821 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,10 @@
4848
"preinteg:local:nightwatch:firefox": "http-server ./build/dev -s &",
4949
"integ:local:nightwatch:firefox": "nightwatch -e firefox",
5050
"postinteg:local:nightwatch:firefox": "kill $(lsof -t -i:8080)",
51-
"smoke:local": "cross-env URL=$URL MONITOR_ID=$MONITOR ENDPOINT=$ENDPOINT npx playwright test --config=playwright.local.config.ts --headed",
52-
"smoke": "cross-env URL=$URL MONITOR_ID=$MONITOR ENDPOINT=$ENDPOINT npx playwright test --headed",
53-
"smoke:headless": "cross-env URL=$URL MONITOR_ID=$MONITOR ENDPOINT=$ENDPOINT npx playwright test"
51+
"smoke:local:headless": "cross-env URL=$URL MONITOR_ID=$MONITOR ENDPOINT=$ENDPOINT NAME=$NAME npx playwright test --config=playwright.local.config.ts",
52+
"smoke:local": "cross-env URL=$URL MONITOR_ID=$MONITOR ENDPOINT=$ENDPOINT NAME=$NAME npx playwright test --config=playwright.local.config.ts --headed",
53+
"smoke": "cross-env URL=$URL MONITOR_ID=$MONITOR ENDPOINT=$ENDPOINT NAME=$NAME npx playwright test --headed",
54+
"smoke:headless": "cross-env URL=$URL MONITOR_ID=$MONITOR ENDPOINT=$ENDPOINT NAME=$NAME npx playwright test"
5455
},
5556
"devDependencies": {
5657
"@babel/plugin-transform-runtime": "^7.16.0",
@@ -98,6 +99,7 @@
9899
},
99100
"dependencies": {
100101
"@aws-crypto/sha256-js": "^1.1.0",
102+
"@aws-sdk/client-rum": "^3.76.0",
101103
"@aws-sdk/fetch-http-handler": "^3.36.0",
102104
"@aws-sdk/protocol-http": "^3.36.0",
103105
"@aws-sdk/signature-v4": "^3.36.0",

playwright.config.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ const { devices } = require('@playwright/test');
55
const config = {
66
forbidOnly: !!process.env.CI,
77
testDir: 'src/__smoke-test__',
8-
retries: process.env.CI ? 2 : 0,
8+
retries: process.env.CI ? 2 : 2,
9+
timeout: 300000,
910
use: {
1011
trace: 'on-first-retry'
1112
},

playwright.local.config.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@ const { devices } = require('@playwright/test');
55
const config = {
66
forbidOnly: !!process.env.CI,
77
testDir: 'src/__smoke-test__',
8-
retries: process.env.CI ? 2 : 0,
8+
retries: process.env.CI ? 2 : 2,
9+
timeout: 300000,
910
webServer: {
1011
command: 'npm run server',
11-
url: 'http://localhost:8080/',
12-
timeout: 120 * 1000,
12+
url: 'http://localhost:9000/',
13+
timeout: 300000,
1314
reuseExistingServer: !process.env.CI
1415
},
1516
use: {

src/__smoke-test__/dataplane-integ.spec.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import {
99
// Environment variables set through CLI command
1010
const ENDPOINT = process.env.ENDPOINT;
1111
const MONITOR_ID = process.env.MONITOR;
12-
const TEST_URL = process.env.URL || 'http://localhost:8080/smoke.html';
12+
const TEST_URL = process.env.URL || 'http://localhost:9000/smoke.html';
1313

1414
const TARGET_URL = ENDPOINT + MONITOR_ID + '/';
1515

@@ -29,9 +29,6 @@ function isDataPlaneRequest(response): boolean {
2929
);
3030
}
3131

32-
// Run the tests in parallel
33-
test.describe.configure({ mode: 'parallel' });
34-
3532
test('when web client calls PutRumEvents then the response code is 200', async ({
3633
page
3734
}) => {

0 commit comments

Comments
 (0)