diff --git a/app/ui/archiveTile.js b/app/ui/archiveTile.js index 335e00fe..79886d3d 100644 --- a/app/ui/archiveTile.js +++ b/app/ui/archiveTile.js @@ -142,7 +142,7 @@ function archiveDetails(translate, archive) { module.exports = function(state, emit, archive) { return html`

diff --git a/app/ui/expiryOptions.js b/app/ui/expiryOptions.js index 0a3268a6..b0fe7876 100644 --- a/app/ui/expiryOptions.js +++ b/app/ui/expiryOptions.js @@ -43,7 +43,7 @@ module.exports = function(state, emit) { state.downloadCount = value; emit('render'); }, - 'expire-after-dl-count-dropdown' + 'expire-after-dl-count-select' ), dlCountSelect ); @@ -70,7 +70,7 @@ module.exports = function(state, emit) { state.timeLimit = value; emit('render'); }, - 'expire-after-time-dropdown' + 'expire-after-time-select' ), timeSelect ); diff --git a/test/integration/download-tests.js b/test/integration/download-tests.js index 3dfdee9e..908cb29c 100644 --- a/test/integration/download-tests.js +++ b/test/integration/download-tests.js @@ -42,8 +42,8 @@ describe('Firefox Send', function() { `${testFilesPath}/${testFiles[0]}` ); browser.waitForExist(homePage.uploadButton); - browser.waitForExist(homePage.downloadCountDropdown); - browser.selectByIndex(homePage.downloadCountDropdown, 1); + browser.waitForExist(homePage.downloadCountSelect); + browser.selectByIndex(homePage.downloadCountSelect, 1); browser.click(homePage.uploadButton); browser.waitForExist(homePage.shareUrl); const downloadPage = new DownloadPage(browser.getValue(homePage.shareUrl)); @@ -51,10 +51,10 @@ describe('Firefox Send', function() { downloadPage.download(); browser.waitForExist(downloadPage.downloadComplete); browser.back(); - browser.waitForExist(homePage.expiresAfterText); - assert.ok( - browser.getText(homePage.expiresAfterText).substring(0, 24) === - expectedExpiresAfterText + browser.waitForExist(`#archive-${downloadPage.fileId}`); + assert.equal( + browser.getText(`#archive-${downloadPage.fileId} > div`).substring(0, 24), + expectedExpiresAfterText ); }); }); diff --git a/test/integration/pages/desktop/download_page.js b/test/integration/pages/desktop/download_page.js index 7115a248..0e9b727c 100644 --- a/test/integration/pages/desktop/download_page.js +++ b/test/integration/pages/desktop/download_page.js @@ -4,6 +4,7 @@ const Page = require('./page'); class DownloadPage extends Page { constructor(path) { super(path); + this.fileId = /download\/(\w+)\/#/.exec(path)[1]; this.downloadButton = '#download-btn'; this.downloadComplete = '#download-complete'; } diff --git a/test/integration/pages/desktop/home_page.js b/test/integration/pages/desktop/home_page.js index 67cb66fc..5679f1b8 100644 --- a/test/integration/pages/desktop/home_page.js +++ b/test/integration/pages/desktop/home_page.js @@ -9,8 +9,7 @@ class HomePage extends Page { this.uploadButton = '#upload-btn'; this.progress = 'progress'; this.shareUrl = '#share-url'; - this.downloadCountDropdown = '#expire-after-dl-count-dropdown'; - this.expiresAfterText = '.text-xs.text-grey-dark.w-full.mt-2.mb-2'; + this.downloadCountSelect = '#expire-after-dl-count-select'; } waitForPageToLoad() {