File tree Expand file tree Collapse file tree 3 files changed +10
-2
lines changed
visual-js/visual-playwright/src Expand file tree Collapse file tree 3 files changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -160,6 +160,7 @@ ${e instanceof Error ? e.message : JSON.stringify(e)}
160
160
diffingMethod,
161
161
diffingMethodTolerance,
162
162
diffingMethodSensitivity,
163
+ diffingOptions,
163
164
} = options ?? { } ;
164
165
const {
165
166
animations = 'disabled' ,
@@ -337,6 +338,7 @@ ${e instanceof Error ? e.message : JSON.stringify(e)}
337
338
diffingMethod,
338
339
diffingMethodSensitivity,
339
340
diffingMethodTolerance,
341
+ diffingOptions,
340
342
} ) ;
341
343
342
344
const { diffs } = await this . api . createSnapshot ( {
Original file line number Diff line number Diff line change 2
2
DiffingMethod ,
3
3
DiffingMethodSensitivity ,
4
4
DiffingMethodToleranceIn ,
5
+ DiffingOptionsIn ,
5
6
RegionIn ,
6
7
VisualEnvOpts ,
7
8
} from '@saucelabs/visual' ;
@@ -35,6 +36,7 @@ export interface SauceVisualParams {
35
36
diffingMethod ?: DiffingMethod ;
36
37
diffingMethodTolerance ?: DiffingMethodToleranceIn ;
37
38
diffingMethodSensitivity ?: DiffingMethodSensitivity ;
39
+ diffingOptions ?: DiffingOptionsIn ;
38
40
}
39
41
40
42
export interface PlaywrightEnvOpts extends VisualEnvOpts {
Original file line number Diff line number Diff line change 3
3
DiffingMethod ,
4
4
DiffingMethodSensitivity ,
5
5
DiffingMethodToleranceIn ,
6
+ DiffingOptionsIn ,
6
7
getEnvOpts ,
7
8
OperatingSystem ,
8
9
SnapshotIn ,
@@ -110,6 +111,7 @@ export const buildSnapshotMetadata = ({
110
111
diffingMethod,
111
112
diffingMethodTolerance,
112
113
diffingMethodSensitivity,
114
+ diffingOptions,
113
115
} : {
114
116
browserName : string | undefined ;
115
117
browserVersion : string | undefined ;
@@ -119,13 +121,15 @@ export const buildSnapshotMetadata = ({
119
121
name : string ;
120
122
ignoreRegions : SnapshotIn [ 'ignoreRegions' ] ;
121
123
diffingMethod : DiffingMethod | undefined ;
122
- diffingMethodTolerance ?: DiffingMethodToleranceIn ;
123
- diffingMethodSensitivity ?: DiffingMethodSensitivity ;
124
+ diffingMethodTolerance : DiffingMethodToleranceIn | undefined ;
125
+ diffingMethodSensitivity : DiffingMethodSensitivity | undefined ;
126
+ diffingOptions : DiffingOptionsIn | undefined ;
124
127
} ) : Omit < SnapshotIn , 'uploadId' > => {
125
128
return {
126
129
diffingMethod : diffingMethod || DiffingMethod . Balanced ,
127
130
diffingMethodTolerance,
128
131
diffingMethodSensitivity,
132
+ diffingOptions,
129
133
browser : getKnownBrowserType ( browserName ) ,
130
134
browserVersion : browserVersion ? `Playwright - ${ browserVersion } ` : null ,
131
135
buildUuid : buildId ,
You can’t perform that action at this time.
0 commit comments