File tree 3 files changed +14
-8
lines changed
integration-tests/playwright
datadog-plugin-playwright/src
dd-trace/src/plugins/util
3 files changed +14
-8
lines changed Original file line number Diff line number Diff line change @@ -17,7 +17,8 @@ const {
17
17
TEST_SOURCE_START ,
18
18
TEST_TYPE ,
19
19
TEST_SOURCE_FILE ,
20
- TEST_CONFIGURATION_BROWSER_NAME ,
20
+ TEST_PARAMETERS ,
21
+ TEST_BROWSER_NAME ,
21
22
TEST_IS_NEW ,
22
23
TEST_IS_RETRY ,
23
24
TEST_EARLY_FLAKE_ENABLED ,
@@ -153,7 +154,12 @@ versions.forEach((version) => {
153
154
assert . propertyVal ( testEvent . content . meta , 'test.customtag' , 'customvalue' )
154
155
assert . propertyVal ( testEvent . content . meta , 'test.customtag2' , 'customvalue2' )
155
156
// Adds the browser used
156
- assert . propertyVal ( testEvent . content . meta , TEST_CONFIGURATION_BROWSER_NAME , 'chromium' )
157
+ assert . propertyVal ( testEvent . content . meta , TEST_BROWSER_NAME , 'chromium' )
158
+ assert . propertyVal (
159
+ testEvent . content . meta ,
160
+ TEST_PARAMETERS ,
161
+ JSON . stringify ( { arguments : { browser : 'chromium' } , metadata : { } } )
162
+ )
157
163
assert . exists ( testEvent . content . metrics [ DD_HOST_CPU_COUNT ] )
158
164
} )
159
165
Original file line number Diff line number Diff line change @@ -11,12 +11,13 @@ const {
11
11
TEST_SOURCE_START ,
12
12
TEST_CODE_OWNERS ,
13
13
TEST_SOURCE_FILE ,
14
- TEST_CONFIGURATION_BROWSER_NAME ,
14
+ TEST_PARAMETERS ,
15
15
TEST_IS_NEW ,
16
16
TEST_IS_RETRY ,
17
17
TEST_EARLY_FLAKE_ENABLED ,
18
18
TELEMETRY_TEST_SESSION ,
19
- TEST_RETRY_REASON
19
+ TEST_RETRY_REASON ,
20
+ TEST_BROWSER_NAME
20
21
} = require ( '../../dd-trace/src/plugins/util/test' )
21
22
const { RESOURCE_NAME } = require ( '../../../ext/tags' )
22
23
const { COMPONENT } = require ( '../../dd-trace/src/constants' )
@@ -202,7 +203,9 @@ class PlaywrightPlugin extends CiPlugin {
202
203
extraTags [ TEST_SOURCE_FILE ] = testSourceFile || testSuite
203
204
}
204
205
if ( browserName ) {
205
- extraTags [ TEST_CONFIGURATION_BROWSER_NAME ] = browserName
206
+ // Added as parameter too because it should affect the test fingerprint
207
+ extraTags [ TEST_PARAMETERS ] = JSON . stringify ( { arguments : { browser : browserName } , metadata : { } } )
208
+ extraTags [ TEST_BROWSER_NAME ] = browserName
206
209
}
207
210
208
211
return super . startTestSpan ( testName , testSuite , testSuiteSpan , extraTags )
Original file line number Diff line number Diff line change @@ -52,8 +52,6 @@ const TEST_MODULE_ID = 'test_module_id'
52
52
const TEST_SUITE_ID = 'test_suite_id'
53
53
const TEST_TOOLCHAIN = 'test.toolchain'
54
54
const TEST_SKIPPED_BY_ITR = 'test.skipped_by_itr'
55
- // Browser used in browser test. Namespaced by test.configuration because it affects the fingerprint
56
- const TEST_CONFIGURATION_BROWSER_NAME = 'test.configuration.browser_name'
57
55
// Early flake detection
58
56
const TEST_IS_NEW = 'test.is_new'
59
57
const TEST_IS_RETRY = 'test.is_retry'
@@ -143,7 +141,6 @@ module.exports = {
143
141
MOCHA_WORKER_TRACE_PAYLOAD_CODE ,
144
142
TEST_SOURCE_START ,
145
143
TEST_SKIPPED_BY_ITR ,
146
- TEST_CONFIGURATION_BROWSER_NAME ,
147
144
TEST_IS_NEW ,
148
145
TEST_IS_RETRY ,
149
146
TEST_EARLY_FLAKE_ENABLED ,
You can’t perform that action at this time.
0 commit comments