aboutsummaryrefslogblamecommitdiffstats
path: root/vendor/blueimp/jquery-file-upload/wdio/test/specs/01-file-upload.js
blob: 0cc2782e9e114819a0354f74e1413cc780e85dfd (plain) (tree)
1
2
3
4
5
6
7
8
9
10









                                                  


                                   

                                          
      
                                                         

    



                                                        

    
'use strict'

/* global browser, describe, it */

const FileUpload = require('../pages/file-upload')
const assetsDir = browser.config.assetsDir

describe('File Upload', () => {
  if (!assetsDir) return

  it('uploads files', async () => {
    await FileUpload.open()
    await FileUpload.upload([
      assetsDir + 'black+white-60x40.gif',
      assetsDir + 'black+white-3x2.jpg'
    ])
    await browser.saveAndDiffScreenshot('Files uploaded')
  })

  it('deletes files', async () => {
    await FileUpload.open()
    await FileUpload.delete()
    await browser.saveAndDiffScreenshot('Files deleted')
  })
})