File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed
x-pack/plugins/security_solution/cypress/support Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change 11/*
2+
23 * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
34 * or more contributor license agreements. Licensed under the Elastic License;
45 * you may not use this file except in compliance with the Elastic License.
@@ -45,15 +46,14 @@ Cypress.Commands.add(
4546 prevSubject : 'element' ,
4647 } ,
4748 ( input , fileName , fileType = 'text/plain' ) => {
48- cy . fixture ( fileName )
49- . then ( ( content ) => Cypress . Blob . base64StringToBlob ( content , fileType ) )
50- . then ( ( blob ) => {
51- const testFile = new File ( [ blob ] , fileName , { type : fileType } ) ;
52- const dataTransfer = new DataTransfer ( ) ;
49+ cy . fixture ( fileName ) . then ( ( content ) => {
50+ const blob = Cypress . Blob . base64StringToBlob ( content , fileType ) ;
51+ const testFile = new File ( [ blob ] , fileName , { type : fileType } ) ;
52+ const dataTransfer = new DataTransfer ( ) ;
5353
54- dataTransfer . items . add ( testFile ) ;
55- input [ 0 ] . files = dataTransfer . files ;
56- return input ;
57- } ) ;
54+ dataTransfer . items . add ( testFile ) ;
55+ input [ 0 ] . files = dataTransfer . files ;
56+ return input ;
57+ } ) ;
5858 }
5959) ;
You can’t perform that action at this time.
0 commit comments