File tree 8 files changed +0
-84
lines changed
8 files changed +0
-84
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,6 @@ const fs = require('fs');
3
3
const path = require ( 'path' ) ;
4
4
5
5
const benchmarkPlugin = require ( './e2e/cypress/plugins/benchmark/index' ) ;
6
- const compareScreenshots = require ( './e2e/cypress/plugins/compareScreenshots' ) ;
7
6
const readProvisions = require ( './e2e/cypress/plugins/readProvisions' ) ;
8
7
const typescriptPreprocessor = require ( './e2e/cypress/plugins/typescriptPreprocessor' ) ;
9
8
@@ -29,7 +28,6 @@ module.exports = defineConfig({
29
28
}
30
29
31
30
on ( 'task' , {
32
- compareScreenshots,
33
31
readProvisions : ( filePaths ) => readProvisions ( { CWD : process . cwd ( ) , filePaths } ) ,
34
32
} ) ;
35
33
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ const fs = require('fs');
2
2
const path = require ( 'path' ) ;
3
3
4
4
const benchmarkPlugin = require ( './benchmark' ) ;
5
- const compareScreenshots = require ( './compareScreenshots' ) ;
6
5
const extendConfig = require ( './extendConfig' ) ;
7
6
const readProvisions = require ( './readProvisions' ) ;
8
7
const typescriptPreprocessor = require ( './typescriptPreprocessor' ) ;
@@ -13,7 +12,6 @@ module.exports = (on, config) => {
13
12
}
14
13
15
14
on ( 'file:preprocessor' , typescriptPreprocessor ) ;
16
- on ( 'task' , { compareScreenshots, readProvisions } ) ;
17
15
on ( 'task' , {
18
16
log ( { message, optional } ) {
19
17
optional ? console . log ( message , optional ) : console . log ( message ) ;
Original file line number Diff line number Diff line change 1
1
import 'cypress-file-upload' ;
2
2
3
- Cypress . Commands . add ( 'compareScreenshots' , ( config ) => {
4
- cy . task ( 'compareScreenshots' , {
5
- config,
6
- screenshotsFolder : Cypress . config ( 'screenshotsFolder' ) ,
7
- specName : Cypress . spec . name ,
8
- } ) ;
9
- } ) ;
10
-
11
3
Cypress . Commands . add ( 'logToConsole' , ( message , optional ) => {
12
4
cy . task ( 'log' , { message : '(' + new Date ( ) . toISOString ( ) + ') ' + message , optional } ) ;
13
5
} ) ;
Original file line number Diff line number Diff line change 1
1
/// <reference types="cypress" />
2
2
3
- interface CompareScreenshotsConfig {
4
- name : string ;
5
- threshold ?: number ;
6
- }
7
-
8
3
declare namespace Cypress {
9
4
interface Chainable {
10
- compareScreenshots ( config : CompareScreenshotsConfig | string ) : Chainable ;
11
5
logToConsole ( message : string , optional ?: unknown ) : void ;
12
6
readProvisions ( filePaths : string [ ] ) : Chainable ;
13
7
getJSONFilesFromDir ( dirPath : string ) : Chainable ;
Original file line number Diff line number Diff line change @@ -21,9 +21,7 @@ interface ConfigurePanelDefault {
21
21
route : string | RegExp ;
22
22
} ;
23
23
dashboardUid : string ;
24
- matchScreenshot : boolean ;
25
24
saveDashboard : boolean ;
26
- screenshotName : string ;
27
25
visitDashboardAtStart : boolean ; // @todo remove when possible
28
26
}
29
27
@@ -60,9 +58,7 @@ export const configurePanel = (config: PartialAddPanelConfig | PartialEditPanelC
60
58
route : '/api/ds/query' ,
61
59
} ,
62
60
dashboardUid : lastAddedDashboardUid ,
63
- matchScreenshot : false ,
64
61
saveDashboard : true ,
65
- screenshotName : 'panel-visualization' ,
66
62
visitDashboardAtStart : true ,
67
63
...config ,
68
64
} ;
@@ -72,10 +68,8 @@ export const configurePanel = (config: PartialAddPanelConfig | PartialEditPanelC
72
68
dashboardUid,
73
69
dataSourceName,
74
70
isEdit,
75
- matchScreenshot,
76
71
panelTitle,
77
72
queriesForm,
78
- screenshotName,
79
73
timeRange,
80
74
visitDashboardAtStart,
81
75
visualizationName,
@@ -157,15 +151,6 @@ export const configurePanel = (config: PartialAddPanelConfig | PartialEditPanelC
157
151
// Wait for RxJS
158
152
cy . wait ( timeout ?? Cypress . config ( ) . defaultCommandTimeout ) ;
159
153
160
- if ( matchScreenshot ) {
161
- let visualization ;
162
-
163
- visualization = e2e . components . Panels . Panel . containerByTitle ( panelTitle ) . find ( '.panel-content' ) ;
164
-
165
- visualization . scrollIntoView ( ) . screenshot ( screenshotName ) ;
166
- cy . compareScreenshots ( screenshotName ) ;
167
- }
168
-
169
154
// @todo remove `wrap` when possible
170
155
return cy . wrap ( { config : fullConfig } , { log : false } ) ;
171
156
} ) ;
Original file line number Diff line number Diff line change 159
159
"babel-loader" : " 9.1.3" ,
160
160
"babel-plugin-angularjs-annotate" : " 0.10.0" ,
161
161
"babel-plugin-macros" : " 3.1.0" ,
162
- "blink-diff" : " 1.0.13" ,
163
162
"blob-polyfill" : " 7.0.20220408" ,
164
163
"browserslist" : " ^4.21.4" ,
165
164
"chance" : " ^1.0.10" ,
Original file line number Diff line number Diff line change @@ -17484,7 +17484,6 @@ __metadata:
17484
17484
babel-plugin-angularjs-annotate: "npm:0.10.0"
17485
17485
babel-plugin-macros: "npm:3.1.0"
17486
17486
baron: "npm:3.0.3"
17487
- blink-diff: "npm:1.0.13"
17488
17487
blob-polyfill: "npm:7.0.20220408"
17489
17488
brace: "npm:0.11.1"
17490
17489
browserslist: "npm:^4.21.4"
You can’t perform that action at this time.
0 commit comments