-
-
Notifications
You must be signed in to change notification settings - Fork 218
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Establishes strict test order. Extracts master upgrade out of main test because we want to run other test assertions over current branch, not master. Adds mocha bail so we fail fast if upgrade fails. #9257
- Loading branch information
1 parent
74b4314
commit 1e9efb7
Showing
3 changed files
with
51 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
const loginPage = require('@page-objects/default/login/login.wdio.page'); | ||
const upgradePage = require('@page-objects/upgrade/upgrade.wdio.page'); | ||
const commonPage = require('@page-objects/default/common/common.wdio.page'); | ||
const aboutPage = require('@page-objects/default/about/about.wdio.page'); | ||
const constants = require('@constants'); | ||
|
||
const upgradeVersion = async () => { | ||
await upgradePage.goToUpgradePage(); | ||
await upgradePage.expandPreReleasesAccordion(); | ||
|
||
await (await upgradePage.getInstallButton('master')).click(); | ||
await (await upgradePage.upgradeModalConfirm()).click(); | ||
|
||
await (await upgradePage.cancelUpgradeButton()).waitForDisplayed(); | ||
await (await upgradePage.deploymentInProgress()).waitForDisplayed(); | ||
await (await upgradePage.deploymentInProgress()).waitForDisplayed({ reverse: true, timeout: 100000 }); | ||
|
||
await (await upgradePage.deploymentComplete()).waitForDisplayed(); | ||
}; | ||
|
||
|
||
describe('Performing an upgrade from current branch to master', () => { | ||
it('should upgrade from current version to master', async () => { | ||
await loginPage.cookieLogin({ | ||
username: constants.USERNAME, | ||
password: constants.PASSWORD, | ||
createUser: false | ||
}); | ||
|
||
await upgradeVersion('master'); | ||
|
||
expect(await upgradePage.getBuild()).to.include('alpha'); | ||
await commonPage.goToAboutPage(); | ||
await commonPage.waitForPageLoaded(); | ||
await (await aboutPage.aboutCard()).waitForDisplayed(); | ||
expect(await aboutPage.getVersion()).to.include('master'); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters