Updated to work on Prod

This commit is contained in:
2020-10-07 17:37:54 -07:00
parent bb1d7eaaf9
commit 0e29aa7ccc
2 changed files with 11 additions and 10 deletions

View File

@@ -29,7 +29,7 @@ exports.config = {
signup: 'https://app-qa.journeysmap.com/Journey/index.html#/signup', signup: 'https://app-qa.journeysmap.com/Journey/index.html#/signup',
login: 'https://app-qa.journeysmap.com/Journey/index.html#/login', login: 'https://app-qa.journeysmap.com/Journey/index.html#/login',
code: 'N0R7Y7RO', //QA N0R7Y7RO //PROD 0W3SNBQ7 code: 'N0R7Y7RO', //QA N0R7Y7RO //PROD 0W3SNBQ7
username: 'AutomatedTest' + mm + dd + yyyy + hour + minute + '@journeysmap.com', createUsername: 'AutomatedTest' + mm + dd + yyyy + hour + minute + '@journeysmap.com',
password: '3Dm!nAuto' password: '3Dm!nAuto'
} }

View File

@@ -133,7 +133,7 @@ describe('Create Account script', function () {
await EmailLinkText.click().then(function() { await EmailLinkText.click().then(function() {
browser.sleep(1000); browser.sleep(1000);
}); });
await EmailTextBox.sendKeys(browser.params.username).then(function() { await EmailTextBox.sendKeys(browser.params.createUsername).then(function() {
browser.sleep(1000); browser.sleep(1000);
}); });
await PageTwoNextButton.click().then(function() { await PageTwoNextButton.click().then(function() {
@@ -193,7 +193,7 @@ describe('Create Account script', function () {
}); });
expect(await ConnectionGreetingText.getText()).toEqual('Connect with your code!'); expect(await ConnectionGreetingText.getText()).toEqual('Connect with your code!');
await ConnectionCodeTextBox.sendKeys('JMHZ19').then(function() { await ConnectionCodeTextBox.sendKeys('JMHZ19').then(function() {
browser.sleep(1000); browser.sleep(1500);
}); });
expect(await ConnectionCodeSubText.getText()).toContain("Not sure what this is? Don't feel bad, just skip ahead!"); expect(await ConnectionCodeSubText.getText()).toContain("Not sure what this is? Don't feel bad, just skip ahead!");
await ConnectionCodeNextButton.click().then(function() { await ConnectionCodeNextButton.click().then(function() {
@@ -202,9 +202,10 @@ describe('Create Account script', function () {
expect(await ConnectionCodeValidationText.getText()).toContain("Hmmm we don't recognize your code, please try again. Please contact help@journeysmap.com."); expect(await ConnectionCodeValidationText.getText()).toContain("Hmmm we don't recognize your code, please try again. Please contact help@journeysmap.com.");
await ConnectionCodeTextBox.clear().then(function() { await ConnectionCodeTextBox.clear().then(function() {
ConnectionCodeTextBox.sendKeys(browser.params.code); ConnectionCodeTextBox.sendKeys(browser.params.code);
browser.sleep(1500);
}); });
await ConnectionCodeNextButton.click().then(function() { await ConnectionCodeNextButton.click().then(function() {
browser.sleep(2500); browser.sleep(5000);
}); });
//What do you want to explore? (page) //What do you want to explore? (page)
browser.wait(EC.visibilityOf(WhatDoYouWantToExplorePage)).then(function() { browser.wait(EC.visibilityOf(WhatDoYouWantToExplorePage)).then(function() {
@@ -215,20 +216,20 @@ describe('Create Account script', function () {
expect(await LearnMySkillsButton.getText()).toEqual('Learn My Skills'); expect(await LearnMySkillsButton.getText()).toEqual('Learn My Skills');
expect(await ExploreCareersButton.getText()).toEqual('Explore Careers'); expect(await ExploreCareersButton.getText()).toEqual('Explore Careers');
await CloseXIcon.click().then(function() { await CloseXIcon.click().then(function() {
browser.sleep(2500); browser.sleep(5000);
}); });
//Dashboard //Dashboard
browser.waitForAngular(); browser.waitForAngular();
expect(await JourneysDashboardGreeting.getText()).toEqual('Hi, Jh'); expect(await JourneysDashboardGreeting.getText()).toEqual('Hi, Jh');
//Update Security Question //Update Security Question
await ProfileImageIcon.click().then(function() { await ProfileImageIcon.click().then(function() {
browser.sleep(1000); browser.sleep(2500);
}); });
browser.actions().mouseMove(ProfileLinkText).perform().then(function() { browser.actions().mouseMove(ProfileLinkText).perform().then(function() {
browser.sleep(1500); browser.sleep(1500);
}); });
await ProfileLinkText.click().then(function() { await ProfileLinkText.click().then(function() {
browser.sleep(1000); browser.sleep(1500);
}); });
expect(await AccountInformation.getText()).toEqual('Account Information'); expect(await AccountInformation.getText()).toEqual('Account Information');
await ManageSecurityQuestionsButton.click().then(function() { await ManageSecurityQuestionsButton.click().then(function() {
@@ -335,7 +336,7 @@ function Login() {
expect(await PageOneValidationText.getText()).toEqual("Oops. Looks like we don't recognize your information. Please try again. Or contact help@journeysmap.com."); expect(await PageOneValidationText.getText()).toEqual("Oops. Looks like we don't recognize your information. Please try again. Or contact help@journeysmap.com.");
await UsernameTextBoxTwo.clear().then(function() { await UsernameTextBoxTwo.clear().then(function() {
browser.sleep(1000); browser.sleep(1000);
UsernameTextBoxTwo.sendKeys(browser.params.username); UsernameTextBoxTwo.sendKeys(browser.params.createUsername);
}); });
await NextButton.click().then(function() { await NextButton.click().then(function() {
browser.sleep(2500); browser.sleep(2500);
@@ -354,7 +355,7 @@ function Login() {
browser.sleep(2500); browser.sleep(2500);
}); });
expect(await PageGreetingText.getText()).toEqual("Can't Get Into Your Account?"); expect(await PageGreetingText.getText()).toEqual("Can't Get Into Your Account?");
await UsernameTextBoxTwo.sendKeys(browser.params.username); await UsernameTextBoxTwo.sendKeys(browser.params.createUsername);
await NextButton.click().then(function() { await NextButton.click().then(function() {
browser.sleep(2500); browser.sleep(2500);
}); });
@@ -443,7 +444,7 @@ function LoginWithNewPassword() {
browser.get(browser.params.login); browser.get(browser.params.login);
browser.sleep(2500); browser.sleep(2500);
expect(await LoginPageGreetingText.getText()).toEqual('Login and start exploring.'); expect(await LoginPageGreetingText.getText()).toEqual('Login and start exploring.');
await UsernameTextBox.sendKeys(browser.params.username); await UsernameTextBox.sendKeys(browser.params.createUsername);
await PasswordTextBox.sendKeys(browser.params.password).then(function() { await PasswordTextBox.sendKeys(browser.params.password).then(function() {
browser.sleep(1000); browser.sleep(1000);
}); });