send/test/integration/progress-tests.js

23 lines
744 B
JavaScript
Raw Normal View History

2018-10-04 00:39:39 +00:00
/* global browser document */
2018-10-02 20:15:02 +00:00
const assert = require('assert');
2018-10-04 00:39:39 +00:00
const ProgressPage = require('./pages/desktop/progress_page');
const HomePage = require('./pages/desktop/home_page');
2018-10-02 20:15:02 +00:00
2018-10-04 00:39:39 +00:00
describe('Firefox Send progress page', function() {
beforeEach(function() {
2018-10-02 20:15:02 +00:00
browser.url('/');
});
2018-10-04 00:39:39 +00:00
it('should show an icon while an upload is in progress', function() {
2018-10-02 20:15:02 +00:00
browser.execute(() => {
document.getElementById('file-upload').style.display = 'block';
});
browser.waitForExist('#file-upload');
2018-10-04 00:39:39 +00:00
const homePage = new HomePage();
2018-10-02 20:15:02 +00:00
browser.chooseFile('#file-upload', __filename);
browser.click(homePage.readyToSend);
2018-10-04 00:39:39 +00:00
const progressPage = new ProgressPage();
2018-10-02 20:15:02 +00:00
assert.ok(progressPage.waitForPageToLoad());
});
});