unsure when reset comes in
This commit is contained in:
12
test/test.js
12
test/test.js
@@ -120,7 +120,7 @@ describe('Application life cycle test', function () {
|
|||||||
await waitForElement(By.xpath(`//h1[contains(., "Welcome")]`));
|
await waitForElement(By.xpath(`//h1[contains(., "Welcome")]`));
|
||||||
}
|
}
|
||||||
|
|
||||||
async function loginOIDC(username, password, hasSession) {
|
async function loginOIDC(username, password, hasSession, proceedWithReset) {
|
||||||
browser.manage().deleteAllCookies();
|
browser.manage().deleteAllCookies();
|
||||||
await browser.get(`https://${elementApp.fqdn}/#/login`);
|
await browser.get(`https://${elementApp.fqdn}/#/login`);
|
||||||
await browser.sleep(6000);
|
await browser.sleep(6000);
|
||||||
@@ -142,7 +142,7 @@ describe('Application life cycle test', function () {
|
|||||||
await browser.findElement(By.xpath('//a[contains(., "Continue")]')).click();
|
await browser.findElement(By.xpath('//a[contains(., "Continue")]')).click();
|
||||||
await browser.sleep(2000);
|
await browser.sleep(2000);
|
||||||
|
|
||||||
if (!hasSession) {
|
if (proceedWithReset) {
|
||||||
await browser.findElement(By.xpath('//div[text()="Proceed with reset"]')).click();
|
await browser.findElement(By.xpath('//div[text()="Proceed with reset"]')).click();
|
||||||
|
|
||||||
await waitForElement(By.xpath('//button[text()="Continue"]'));
|
await waitForElement(By.xpath('//button[text()="Continue"]'));
|
||||||
@@ -285,7 +285,7 @@ describe('Application life cycle test', function () {
|
|||||||
it('can get Element app info', getElementAppInfo);
|
it('can get Element app info', getElementAppInfo);
|
||||||
it('update element-app config', updateSynapseConfig);
|
it('update element-app config', updateSynapseConfig);
|
||||||
|
|
||||||
it('can login via OIDC', loginOIDC.bind(null, USERNAME, PASSWORD, false));
|
it('can login via OIDC', loginOIDC.bind(null, USERNAME, PASSWORD, false, false));
|
||||||
it('create room', createRoom);
|
it('create room', createRoom);
|
||||||
it('can send message', sendMessage);
|
it('can send message', sendMessage);
|
||||||
it('can get app info', getAppInfo);
|
it('can get app info', getAppInfo);
|
||||||
@@ -327,7 +327,7 @@ describe('Application life cycle test', function () {
|
|||||||
it('update element-app config', updateSynapseConfig);
|
it('update element-app config', updateSynapseConfig);
|
||||||
|
|
||||||
it('can get Element app info', getElementAppInfo);
|
it('can get Element app info', getElementAppInfo);
|
||||||
it('can login via OIDC', loginOIDC.bind(null, USERNAME, PASSWORD, true));
|
it('can login via OIDC', loginOIDC.bind(null, USERNAME, PASSWORD, true, false));
|
||||||
it('check room', checkRoom);
|
it('check room', checkRoom);
|
||||||
it('can send message', sendMessage);
|
it('can send message', sendMessage);
|
||||||
|
|
||||||
@@ -346,7 +346,7 @@ describe('Application life cycle test', function () {
|
|||||||
|
|
||||||
it('update element-app config', updateSynapseConfig);
|
it('update element-app config', updateSynapseConfig);
|
||||||
|
|
||||||
it('can login via OIDC', loginOIDC.bind(null, USERNAME, PASSWORD, false));
|
it('can login via OIDC', loginOIDC.bind(null, USERNAME, PASSWORD, false, false));
|
||||||
it('is logged in', isLoggedIn);
|
it('is logged in', isLoggedIn);
|
||||||
it('create room', createRoom);
|
it('create room', createRoom);
|
||||||
it('can send message', sendMessage);
|
it('can send message', sendMessage);
|
||||||
@@ -359,7 +359,7 @@ describe('Application life cycle test', function () {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it('can get Element app info', getElementAppInfo);
|
it('can get Element app info', getElementAppInfo);
|
||||||
it('can login via OIDC', loginOIDC.bind(null, USERNAME, PASSWORD, true));
|
it('can login via OIDC', loginOIDC.bind(null, USERNAME, PASSWORD, true, false));
|
||||||
it('is logged in', isLoggedIn);
|
it('is logged in', isLoggedIn);
|
||||||
it('check room', checkRoom);
|
it('check room', checkRoom);
|
||||||
it('can send message', sendMessage);
|
it('can send message', sendMessage);
|
||||||
|
|||||||
Reference in New Issue
Block a user