From d68bee11d5f5aac1d9579f8e805700beee031db5 Mon Sep 17 00:00:00 2001 From: Juan Huerta Date: Wed, 4 Mar 2020 16:25:56 -0800 Subject: [PATCH] Updated spec name --- config.js | 2 +- createAccount_config.js | 40 ++ createAccount_spec.js | 575 ++++++++++++++++++ ...journeysmap_spec.js => journeysmap_spec.js | 162 +++-- 4 files changed, 725 insertions(+), 54 deletions(-) create mode 100644 createAccount_config.js create mode 100644 createAccount_spec.js rename app_journeysmap_spec.js => journeysmap_spec.js (98%) diff --git a/config.js b/config.js index 4917947..cd26890 100644 --- a/config.js +++ b/config.js @@ -3,7 +3,7 @@ exports.config = { framework: 'jasmine', seleniumAddress: 'http://localhost:4444/wd/hub', - specs: ['app_journeysmap_spec.js'], + specs: ['journeysmap_spec.js'], jasmineNodeOpts: { defaultTimeoutInterval: 360000 diff --git a/createAccount_config.js b/createAccount_config.js new file mode 100644 index 0000000..5e1859b --- /dev/null +++ b/createAccount_config.js @@ -0,0 +1,40 @@ +// config.js + +var today = new Date(); +var mm = today.getMonth()+1; //January is 0 +var dd = today.getDate(); +var yyyy = today.getFullYear(); +var hour = today.getHours(); +var minute = today.getMinutes(); + +exports.config = { + framework: 'jasmine', + seleniumAddress: 'http://localhost:4444/wd/hub', + specs: ['createAccount_spec.js'], + + jasmineNodeOpts: { + defaultTimeoutInterval: 360000 + }, + + capabilities: { + browserName: 'chrome' + }, + + onPrepare: function() { + browser.driver.manage().window().maximize(); + }, + + params: { + username: 'AutomatedTest' + mm + dd + yyyy + hour + minute + '@journeysmap.com' + } + + /*multiCapabilities: [{ + browserName: 'chrome' + }, { + browserName: 'firefox' + }]/*, { + browserName: 'internet explorer' + }], { + browserName: 'safari' + }]*/ +} \ No newline at end of file diff --git a/createAccount_spec.js b/createAccount_spec.js new file mode 100644 index 0000000..247e972 --- /dev/null +++ b/createAccount_spec.js @@ -0,0 +1,575 @@ +//createAccount_spec.js + +describe('OnBoarding script', function () { + + //Open browser + browser.get('https://app-qa.journeysmap.com/Journey/index.html#/signup'); + + it('should have a title', async function () { + await expect(browser.getTitle()).toEqual('Journeys'); + }); + + var FirstNameTextBox = element(by.css('#txtFirstName')); + var LastNameTextBox = element(by.css('#txtLastName')); + var EmailTextBox = element(by.css('#txtEmail')); + var UsernameTextBox = element(by.css('#txtUsername')); + + //Sign Up + SignUp(FirstNameTextBox, LastNameTextBox, EmailTextBox, UsernameTextBox); + + function SignUp(FirstNameTextBox, LastNameTextBox, EmailTextBox, UsernameTextBox) { + it('OnBoarding; should complete the OnBoarding process and create a new account.', async function () { + //Page 1 - First & Last Name + var PageOneGreetingText = element(by.css('tr:nth-child(2) > td > div > div:nth-child(1) > div:nth-child(1)')); + var PageOneValidationText = element(by.css('div:nth-child(1) > .ng-binding:nth-child(5)')); + var PageOneNextButton = element(by.css('tr:nth-child(2) > td > div > div:nth-child(1) > div > div:nth-child(1)')); + //Page 2 - Username + var PageTwoGreetingText = element(by.css('td > div > div:nth-child(2) > div:nth-child(1)')); + var PageTwoSubText = element(by.css('div:nth-child(2) > div:nth-child(2) > div')); + var PageTwoNextButton = element(by.css('div:nth-child(2) > div > div > .btn')); + var PageTwoValidationText = element(by.css('div:nth-child(2) > .ng-scope:nth-child(4)')); + var UsernameLinkText = element(by.linkText('with a username')); + var PageTwoAltGreetingText = element(by.css('td > div > div:nth-child(3) > div:nth-child(1)')); + var PageTwoAltNextButton = element(by.css('div:nth-child(3) > div:nth-child(3) .btn')); + var PageTwoAltValidationText = element(by.css('div:nth-child(3) > .ng-binding')); + var EmailLinkText = element(by.linkText('with your email')); + //Page 3 Password + var PageThreeGreetingText = element(by.css('td > div > div:nth-child(4) > div:nth-child(1)')); + var PasswordTextBoxOne = element(by.css('#txtPw1')); + var EyeIconOne = element(by.css('div:nth-child(2) > .fa-eye')); + var PasswordTextBoxTwo = element(by.css('#txtPw2')); + var PageThreeNextButton = element(by.css('#btnPwNext')); + var PageThreeValidationText = element(by.css('div:nth-child(4) > .ng-binding')); + //Page 4 Birthday + var PageFourGreetingText = element(by.css('td > div > div:nth-child(5) > div:nth-child(1)')); + var DOBMonth = element(by.css('#txtDobMonth')); + var DOBDay = element(by.css('#txtDobDate')); + var DOBYear = element(by.css('#txtDobYear')); + var today = new Date(); + var yyyy = today.getFullYear()-5; + //var Under13 = today.getFullYear()-5;delete + var PageFourValidationText = element(by.css('div:nth-child(5) > .ng-binding')); + var PermissionButton = element(by.css('div:nth-child(1) > div:nth-child(1) > .btn')); + //Page 5 Connection Code + var PageFiveGreetingText = element(by.css('div:nth-child(6) > div:nth-child(1) > div:nth-child(1)')); + var PageFiveSubText = element(by.css('.ng-binding:nth-child(3) > div')); + var CodeButton = element(by.css('.btn:nth-child(2)')); + var ConnectionGreetingText = element(by.css('div:nth-child(6) > div:nth-child(2) > div:nth-child(1)')); + var ConnectionCodeTextBox = element(by.css('#txtConnection')); + var ConnectionCodeSubText = element(by.css('div:nth-child(2) > .ng-binding > div')); + var ConnectionCodeNextButton = element(by.css('div:nth-child(6) > div:nth-child(2) > div:nth-child(3)')); + var ConnectionCodeValidationText = element(by.css('div:nth-child(6) > div:nth-child(2) > .ng-binding')); + //Processing Page + var ProcessingPageText = element(by.css('.ng-binding:nth-child(2)')); + //What Do you want to explore? (page) + var WhatDoYouWantToExplorePage = element(by.css('#divMyProgressBlocker > div:nth-child(3) > div:nth-child(1) > div')); + var DiscoverMyInterestButton = element(by.css('.col-xs-10 > div > div:nth-child(1) > .btn')); + var LearnMySkillsButton = element(by.css('div:nth-child(2) > .btn')); + var ExploreCareersButton = element(by.css('div:nth-child(3) > .btn')); + var CloseXIcon = element(by.css('.fas')); + //Journeys Dashboard + var JourneysDashboardGreeting = element(by.css('.dropdown')); + //Update Security Question + var ProfileImageIcon = element(by.css('.roundCenterBackgroundImage')); + var ProfileLinkText = element(by.linkText('Profile')); + var AccountInformation = element(by.css('.view-title')); + var ManageSecurityQuestionsButton = element(by.css('.btn:nth-child(15)')); + var SecurityQuestion = element(by.css('#secQuestion0')); + var SecuritySelection = element(by.css('option:nth-child(8)')); + var SecurityAnswer = element(by.css('.ng-pristine')); + var SecurityQuestionSaveButton = element(by.css('.col-lg-4 > #photoBtn')); + + //Page 1 - First & Last Name + expect(await PageOneGreetingText.getText()).toEqual("Let's start with the basics."); + expect(await PageOneValidationText.getText()).toEqual("Press enter when you're done."); + await FirstNameTextBox.sendKeys('J').then(function() { + browser.sleep(1000); + }); + await LastNameTextBox.sendKeys('H').then(function() { + browser.sleep(1000); + }); + await PageOneNextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageOneValidationText.getText()).toEqual('Oops! The minimum length is 2 characters.'); + await FirstNameTextBox.sendKeys('H').then(function() { + browser.sleep(1000); + }); + await PageOneNextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageOneValidationText.getText()).toEqual('Oops! The minimum length is 2 characters.'); + await LastNameTextBox.clear().then(function() { + browser.sleep(1000); + LastNameTextBox.sendKeys('AutomatedTesting'); + browser.sleep(1000); + }); + await PageOneNextButton.click().then(function() { + browser.sleep(2500); + }); + //Page 2 - Username + expect(await PageTwoGreetingText.getText()).toEqual('Your email goes here.'); + await EmailTextBox.sendKeys('AutomatedTesting').then(function() { + browser.sleep(1000); + }); + expect(await PageTwoSubText.getText()).toEqual('No email? Create an account with a username instead.'); + await PageTwoNextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageTwoValidationText.getText()).toEqual('Oops! Something is funky. Please enter a valid email address.'); + await UsernameLinkText.click().then(function() { + browser.sleep(1000); + }); + expect(await PageTwoAltGreetingText.getText()).toEqual("Let's make a username!"); + await UsernameTextBox.sendKeys('JHZ').then(function() { + browser.sleep(1000); + }); + await PageTwoAltNextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageTwoAltValidationText.getText()).toEqual('Oops! Please enter a valid username.'); + await EmailLinkText.click().then(function() { + browser.sleep(1000); + }); + await EmailTextBox.sendKeys(browser.params.username).then(function() { + browser.sleep(1000); + }); + await PageTwoNextButton.click().then(function() { + browser.sleep(2500); + }); + //Page 3 Password + expect(await PageThreeGreetingText.getText()).toEqual("Let's keep your account safe and secure."); + await PasswordTextBoxOne.sendKeys('ED'); + await PasswordTextBoxTwo.sendKeys('3Dm!n123'); + await PageThreeNextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageThreeValidationText.getText()).toEqual('Oops! Please make sure both passwords are the same.'); + await EyeIconOne.click().then(function() { + browser.sleep(2500); + }); + await PasswordTextBoxOne.sendKeys('min123').then(function() { + browser.sleep(1000); + }); + await PageThreeNextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageThreeValidationText.getText()).toEqual('Oops! Please make sure both passwords are the same.'); + await EyeIconOne.click().then(function() { + browser.sleep(1000); + }); + await PasswordTextBoxOne.clear().then(function() { + browser.sleep(1000); + PasswordTextBoxOne.sendKeys('3Dm!n123'); + browser.sleep(1000); + }); + await PageThreeNextButton.click().then(function() { + browser.sleep(2500); + }); + //Page 4 Birthday + expect(await PageFourGreetingText.getText()).toEqual("It's Your Birthday! When do we party?"); + await DOBMonth.sendKeys('2'); + await DOBDay.sendKeys('15'); + await DOBYear.sendKeys('2').then(function() { + browser.sleep(1000); + }); + expect(await PageFourValidationText.getText()).toEqual('Please check that date is formatted as MM-DD-YYYY'); + await DOBYear.clear().then(function() { + browser.sleep(1000); + DOBYear.sendKeys(yyyy); + browser.sleep(1000); + }); + expect(await PageFourValidationText.getText()).toEqual("Looks like you're younger than 13. Get your gaurdian's permission before moving ahead!"); + await PermissionButton.click().then(function() { + browser.sleep(2500); + }); + //Page 5 Connection Code + expect(await PageFiveGreetingText.getText()).toEqual('Do you have a connection code?'); + expect(await PageFiveSubText.getText()).toEqual("Not sure what this is? Don't feel bad, just skip ahead!"); + await CodeButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ConnectionGreetingText.getText()).toEqual('Connect with your code!'); + await ConnectionCodeTextBox.sendKeys('JMHZ19').then(function() { + browser.sleep(1000); + }); + expect(await ConnectionCodeSubText.getText()).toContain("Not sure what this is? Don't feel bad, just skip ahead!"); + await ConnectionCodeNextButton.click().then(function() { + browser.sleep(2500); + }); + 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() { + ConnectionCodeTextBox.sendKeys('N0R7Y7RO'); + }); + await ConnectionCodeNextButton.click().then(function() { + browser.sleep(15000); + }); + /*Processing Page + expect(await ProcessingPageText.getText()).toEqual('wtf').then(function() { + browser.sleep(20000); + });*/ + //What do you want to explore? (page) + expect(await WhatDoYouWantToExplorePage.getText()).toEqual('What do you want to explore?'); + expect(await DiscoverMyInterestButton.getText()).toEqual('Discover My Interests'); + expect(await LearnMySkillsButton.getText()).toEqual('Learn My Skills'); + expect(await ExploreCareersButton.getText()).toEqual('Explore Careers'); + await CloseXIcon.click().then(function() { + browser.sleep(2500); + }); + //Dashboard + expect(await JourneysDashboardGreeting.getText()).toEqual('Hi, Jh'); + browser.waitForAngular(); + browser.getCurrentUrl(); + //Update Security Question + await ProfileImageIcon.click().then(function() { + browser.sleep(1000); + }); + browser.actions().mouseMove(ProfileLinkText).perform().then(function() { + browser.sleep(1500); + }); + await ProfileLinkText.click().then(function() { + browser.sleep(1000); + }); + expect(await AccountInformation.getText()).toEqual('Account Information'); + await ManageSecurityQuestionsButton.click().then(function() { + browser.sleep(2500); + }); + await SecurityQuestion.click(); + await SecuritySelection.click(); + await SecurityAnswer.sendKeys('War Games'); + await SecurityQuestionSaveButton.click().then(function() { + browser.sleep(2500); + }); + expect(await AccountInformation.getText()).toEqual('Account Information'); + }); + } + + //Action Calls + SignOut(); + Login(); + SignOut(); + LoginWithNewPassword(); +}); + +function SignOut() { + it(': SignOut; should log out of journeysmap.', async function () { + var ProfileImage = element(by.css('.roundCenterBackgroundImage')); + var SignOutButton = element(by.css('.dropDownFAEdits:nth-child(5) > .btn')); + + browser.waitForAngular().then(function() { + browser.sleep(1000); + }); + await ProfileImage.click().then(function() { + browser.sleep(1000); + }); + browser.waitForAngular(); + browser.getCurrentUrl(); + await SignOutButton.click().then(function() { + browser.sleep(2500); + }); + }); +} + +function Login() { + it(': Login; should reset new account password and complete Explore Careers task.', async function () { + var LoginPageGreetingText = element(by.css('td > div > div:nth-child(1)')); + var UsernameTextBox = element(by.css('#txtUsername')); + var PasswordTextBox = element(by.css('#txtPassword')); + var LoginPageSubTextOne = element(by.css('div:nth-child(5) > div:nth-child(1)')); + var LoginPageSubTextTwo = element(by.css('div:nth-child(5) > div:nth-child(2)')); + var NextButton = element(by.css('.btn')); + var ValidationText = element(by.css('.ng-scope:nth-child(5)')); + var PasswordEyeIcon = element(by.css('.fa-eye')); + var ClickHereLinkText = element(by.css('div:nth-child(2) > a')); + //Account Recovery + var PageGreetingText = element(by.css('td .ng-scope > div:nth-child(1)')); + var PageOneValidationText = element(by.css('.ng-scope:nth-child(4)')); + //Select Recovery Option + var PageTwoEmailButton = element(by.css('.btn:nth-child(2)')); + var PageTwoSecurityQuestionButton = element(by.css('.btn:nth-child(1)')); + var SecurityQuestionText = element(by.css('.ng-binding')); + var SecurityAnswerTextBox = element(by.css('#txtSecurityAnswer')); + //Reset Password + var NewPasswordTextBoxOne = element(by.css('#txtNewPassword')); + var NewPasswordTextBoxTwo = element(by.css('#txtNewPassword2')); + //What Do you want to explore? + var WhatDoYouWantToExplorePage = element(by.css('#divMyProgressBlocker > div:nth-child(3) > div:nth-child(1) > div')); + var ExploreCareersButton = element(by.css('div:nth-child(3) > .btn')); + var CareerExplorationPageTitle = element(by.css('.col-sm-12')); + var ClusterCardThreeSelectButton = element(by.xpath('//div[3]/div/career-territory-card/territory-card/div/div/div[4]/territory-card-action-bar/div/button')); + var PathwayCardTwoSelectButton = element(by.xpath('//div[2]/div/career-territory-card/territory-card/div/div/div[4]/territory-card-action-bar/div/button')); + var OccupationCardOneLearnMoreIcon = element(by.xpath('//action-learn-more/i')); + var WagesLocalStatText = element(by.css('g:nth-child(3) > g > text')); + //Journeys Dashboard + var JourneysDashboardGreeting = element(by.css('.dropdown')); + + //Navigate to Login page + browser.get('https://app-qa.journeysmap.com/Journey/index.html#/login'); + browser.sleep(2500); + expect(await LoginPageGreetingText.getText()).toEqual('Login and start exploring.'); + await UsernameTextBox.sendKeys('AutomatedTest332020913@edmin.com'); + await PasswordTextBox.sendKeys('edmin123').then(function() { + browser.sleep(1000); + }); + expect(await LoginPageSubTextOne.getText()).toEqual("Don't have an account? Creating one is free! Sign up here."); + expect(await LoginPageSubTextTwo.getText()).toEqual('Forgot your password? Click here.'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ValidationText.getText()).toEqual("Uh oh. Something isn't quite right. Please try again."); + await PasswordEyeIcon.click().then(function() { + browser.sleep(1000); + }); + await PasswordTextBox.clear().then(function() { + PasswordTextBox.sendKeys('EDmin123'); + }); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ValidationText.getText()).toEqual("Uh oh. Something isn't quite right. Please try again."); + await ClickHereLinkText.click().then(function() { + browser.sleep(2500); + }); + //Account Recovery + expect(await PageGreetingText.getText()).toEqual("Can't Get Into Your Account?"); + await UsernameTextBox.sendKeys('AutomatedTest332020913@edmin.com'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageOneValidationText.getText()).toEqual("Oops. Looks like we don't recognize your information. Please try again. Or contact help@journeysmap.com."); + await UsernameTextBox.clear().then(function() { + browser.sleep(1000); + UsernameTextBox.sendKeys(browser.params.username); + }); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + //Select Recovery Option + expect(await PageGreetingText.getText()).toEqual('Awesome. Reset Your Password With Your'); + await PageTwoEmailButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageGreetingText.getText()).toContain('Woo-Hoo! Your Email Has Been Sent!'); + expect(await PageGreetingText.getText()).toContain('The link will expire in 10 minutes!'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + await ClickHereLinkText.click().then(function() { + browser.sleep(2500); + }); + expect(await PageGreetingText.getText()).toEqual("Can't Get Into Your Account?"); + await UsernameTextBox.sendKeys(browser.params.username); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageGreetingText.getText()).toEqual('Awesome. Reset Your Password With Your'); + await PageTwoSecurityQuestionButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageGreetingText.getText()).toEqual('Answer Your Security Questions'); + expect(await SecurityQuestionText.getText()).toEqual('What is your favorite movie?'); + await SecurityAnswerTextBox.sendKeys('2001: A Space Odyssey'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ValidationText.getText()).toEqual("Sorry! Your answers don't match what we have on file. Please contact help@journeysmap.com."); + await SecurityAnswerTextBox.clear().then(function() { + browser.sleep(1000); + SecurityAnswerTextBox.sendKeys('War Games'); + }); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + //Reset Password + expect(await PageGreetingText.getText()).toEqual('Create A New Password!'); + await NewPasswordTextBoxOne.sendKeys('edmin123'); + await NewPasswordTextBoxTwo.sendKeys('EDmin123'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ValidationText.getText()).toEqual('Oops. Looks like both passwords not match. Use 1 uppercase letter or 1 number. Please try again.'); + await NewPasswordTextBoxOne.clear().then(function() { + browser.sleep(1000); + NewPasswordTextBoxOne.sendKeys('3Dm!nAuto'); + }); + await NewPasswordTextBoxTwo.clear().then(function() { + browser.sleep(1000); + NewPasswordTextBoxTwo.sendKeys('3Dm!nAuto'); + }); + await NextButton.click().then(function() { + browser.sleep(5000); + }); + //What do you want to explore? (page) + expect(await WhatDoYouWantToExplorePage.getText()).toEqual('What do you want to explore?'); + await ExploreCareersButton.click().then(function() { + browser.sleep(2500); + }); + expect(await CareerExplorationPageTitle.getText()).toEqual('Career Exploration'); + await ClusterCardThreeSelectButton.click().then(function() { + browser.sleep(2500); + }); + await PathwayCardTwoSelectButton.click().then(function() { + browser.sleep(2500); + }); + await OccupationCardOneLearnMoreIcon.click().then(function() { + browser.sleep(5000); + }); + expect(await WagesLocalStatText.getText()).toEqual('San Diego-Carlsbad, CA'); + //Dashboard + expect(await JourneysDashboardGreeting.getText()).toEqual('Hi, Jh'); + browser.waitForAngular(); + browser.getCurrentUrl(); + }); +} + +function LoginWithNewPassword() { + it(': Login; should log in with new password.', async function () { + var LoginPageGreetingText = element(by.css('td > div > div:nth-child(1)')); + var UsernameTextBox = element(by.css('#txtUsername')); + var PasswordTextBox = element(by.css('#txtPassword')); + var LoginPageSubTextOne = element(by.css('div:nth-child(5) > div:nth-child(1)')); + var LoginPageSubTextTwo = element(by.css('div:nth-child(5) > div:nth-child(2)')); + var NextButton = element(by.css('.btn')); + var ValidationText = element(by.css('.ng-scope:nth-child(5)')); + var PasswordEyeIcon = element(by.css('.fa-eye')); + var ClickHereLinkText = element(by.css('div:nth-child(2) > a')); + //Account Recovery + var PageGreetingText = element(by.css('td .ng-scope > div:nth-child(1)')); + var PageOneValidationText = element(by.css('.ng-scope:nth-child(4)')); + //Select Recovery Option + var PageTwoEmailButton = element(by.css('.btn:nth-child(2)')); + var PageTwoSecurityQuestionButton = element(by.css('.btn:nth-child(1)')); + var SecurityQuestionText = element(by.css('.ng-binding')); + var SecurityAnswerTextBox = element(by.css('#txtSecurityAnswer')); + //Reset Password + var NewPasswordTextBoxOne = element(by.css('#txtNewPassword')); + var NewPasswordTextBoxTwo = element(by.css('#txtNewPassword2')); + //What Do you want to explore? + var WhatDoYouWantToExplorePage = element(by.css('#divMyProgressBlocker > div:nth-child(3) > div:nth-child(1) > div')); + var ExploreCareersButton = element(by.css('div:nth-child(3) > .btn')); + var CareerExplorationPageTitle = element(by.css('.col-sm-12')); + var ClusterCardThreeSelectButton = element(by.xpath('//div[3]/div/career-territory-card/territory-card/div/div/div[4]/territory-card-action-bar/div/button')); + var PathwayCardTwoSelectButton = element(by.xpath('//div[2]/div/career-territory-card/territory-card/div/div/div[4]/territory-card-action-bar/div/button')); + var OccupationCardOneLearnMoreIcon = element(by.xpath('//action-learn-more/i')); + var WagesLocalStatText = element(by.css('g:nth-child(3) > g > text')); + //Journeys Dashboard + var JourneysDashboardGreeting = element(by.css('.dropdown')); + + //Navigate to Login page + browser.get('https://app-qa.journeysmap.com/Journey/index.html#/login'); + browser.sleep(2500); + expect(await LoginPageGreetingText.getText()).toEqual('Login and start exploring.'); + await UsernameTextBox.sendKeys('AutomatedTest332020913@edmin.com'); + await PasswordTextBox.sendKeys('edmin123').then(function() { + browser.sleep(1000); + }); + expect(await LoginPageSubTextOne.getText()).toEqual("Don't have an account? Creating one is free! Sign up here."); + expect(await LoginPageSubTextTwo.getText()).toEqual('Forgot your password? Click here.'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ValidationText.getText()).toEqual("Uh oh. Something isn't quite right. Please try again."); + await PasswordEyeIcon.click().then(function() { + browser.sleep(1000); + }); + await PasswordTextBox.clear().then(function() { + PasswordTextBox.sendKeys('EDmin123'); + }); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ValidationText.getText()).toEqual("Uh oh. Something isn't quite right. Please try again."); + await ClickHereLinkText.click().then(function() { + browser.sleep(2500); + }); + //Account Recovery + expect(await PageGreetingText.getText()).toEqual("Can't Get Into Your Account?"); + await UsernameTextBox.sendKeys('AutomatedTest332020913@edmin.com'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageOneValidationText.getText()).toEqual("Oops. Looks like we don't recognize your information. Please try again. Or contact help@journeysmap.com."); + await UsernameTextBox.clear().then(function() { + browser.sleep(1000); + UsernameTextBox.sendKeys(browser.params.username); + }); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + //Select Recovery Option + expect(await PageGreetingText.getText()).toEqual('Awesome. Reset Your Password With Your'); + await PageTwoEmailButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageGreetingText.getText()).toContain('Woo-Hoo! Your Email Has Been Sent!'); + expect(await PageGreetingText.getText()).toContain('The link will expire in 10 minutes!'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + await ClickHereLinkText.click().then(function() { + browser.sleep(2500); + }); + expect(await PageGreetingText.getText()).toEqual("Can't Get Into Your Account?"); + await UsernameTextBox.sendKeys(browser.params.username); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageGreetingText.getText()).toEqual('Awesome. Reset Your Password With Your'); + await PageTwoSecurityQuestionButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageGreetingText.getText()).toEqual('Answer Your Security Questions'); + expect(await SecurityQuestionText.getText()).toEqual('What is your favorite movie?'); + await SecurityAnswerTextBox.sendKeys('2001: A Space Odyssey'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ValidationText.getText()).toEqual("Sorry! Your answers don't match what we have on file. Please contact help@journeysmap.com."); + await SecurityAnswerTextBox.clear().then(function() { + browser.sleep(1000); + SecurityAnswerTextBox.sendKeys('War Games'); + }); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + //Reset Password + expect(await PageGreetingText.getText()).toEqual('Create A New Password!'); + await NewPasswordTextBoxOne.sendKeys('edmin123'); + await NewPasswordTextBoxTwo.sendKeys('EDmin123'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await ValidationText.getText()).toEqual('Oops. Looks like both passwords not match. Use 1 uppercase letter or 1 number. Please try again.'); + await NewPasswordTextBoxOne.clear().then(function() { + browser.sleep(1000); + NewPasswordTextBoxOne.sendKeys('3Dm!nAuto'); + }); + await NewPasswordTextBoxTwo.clear().then(function() { + browser.sleep(1000); + NewPasswordTextBoxTwo.sendKeys('3Dm!nAuto'); + }); + await NextButton.click().then(function() { + browser.sleep(5000); + }); + //What do you want to explore? (page) + expect(await WhatDoYouWantToExplorePage.getText()).toEqual('What do you want to explore?'); + await ExploreCareersButton.click().then(function() { + browser.sleep(2500); + }); + expect(await CareerExplorationPageTitle.getText()).toEqual('Career Exploration'); + await ClusterCardThreeSelectButton.click().then(function() { + browser.sleep(2500); + }); + await PathwayCardTwoSelectButton.click().then(function() { + browser.sleep(2500); + }); + await OccupationCardOneLearnMoreIcon.click().then(function() { + browser.sleep(5000); + }); + expect(await WagesLocalStatText.getText()).toEqual('San Diego-Carlsbad, CA'); + //Dashboard + expect(await JourneysDashboardGreeting.getText()).toEqual('Hi, Jh'); + browser.waitForAngular(); + browser.getCurrentUrl(); + }); +} \ No newline at end of file diff --git a/app_journeysmap_spec.js b/journeysmap_spec.js similarity index 98% rename from app_journeysmap_spec.js rename to journeysmap_spec.js index 9b32cc4..cdf06b0 100644 --- a/app_journeysmap_spec.js +++ b/journeysmap_spec.js @@ -1,10 +1,9 @@ -//app-journeysmap_spec.js +//journeysmap_spec.js describe('Journeysmap script', function () { //app-journeysmap landing page - var UserNameTextBox = element(by.id('txtUsername')); - var PasswordTextBox = element(by.id('txtPassword')); - var ContinueArrow = element(by.css('.jm-next-circle')); + var UserNameTextBox = element(by.css('#txtUsername')); + var PasswordTextBox = element(by.css('#txtPassword')); //Open browser //browser.driver.manage().window().setSize(1600, 800); @@ -15,29 +14,87 @@ describe('Journeysmap script', function () { }); //Sign In - SignIn(UserNameTextBox, PasswordTextBox, ContinueArrow); + SignIn(UserNameTextBox, PasswordTextBox); it('should have a title', async function () { await expect(browser.getTitle()).toEqual('Journeys'); }); - function SignIn(UserNameTextBox, PasswordTextBox, ContinueArrow) { + function SignIn(UserNameTextBox, PasswordTextBox) { it('should sign into journeysmap.com', async function () { - var PageGreatingText = element(by.css('.col-xs-10 > div:nth-child(1)')); - var PageSubText = element(by.css('.ng-scope:nth-child(4)')); + var PageGreetingText = element(by.css('.onboardingHeader')); + var PageSubText = element(by.css('div:nth-child(5)')); + var NextButton = element(by.css('.btn')); + var PageValidationText = element(by.css('div:nth-child(2) > div > .ng-scope')); + var EC = protractor.ExpectedConditions; + var EyeIcon = element(by.css('div:nth-child(2) > div > div .fa-eye')); + var PasswordRecoveryLinkText = element(by.linkText('forget your password?')); + var CloseXIcon = element(by.css('.overrideButtonColor')); var JourneysGreeting = element(by.css('.dropdown')); - expect(await PageGreatingText.getText()).toEqual('Login and start exploring.'); - expect(await PageSubText.getText()).toEqual('Forgot your password? click here.'); - await UserNameTextBox.sendKeys('QA_AutomatedRegression'); - await PasswordTextBox.sendKeys('3Dm1nAuto'); - await ContinueArrow.click().then(function() { + expect(await PageGreetingText.getText()).toEqual('Login and start exploring.'); + browser.sleep(2500); + await UserNameTextBox.sendKeys('QA_AutomatedRegression').then(function() { + browser.sleep(2500); + }); + await PasswordTextBox.sendKeys('edmin123').then(function() { + browser.sleep(2500); + }); + expect(await PageSubText.getText()).toEqual('Did you forget your password?'); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageValidationText.getText()).toEqual("Uh oh. Something isn't quite right. Please try again."); + await PasswordTextBox.click().then(function() { + browser.sleep(2500); + }); + browser.wait(EC.invisibilityOf(PageValidationText)); + await EyeIcon.click().then(function() { + browser.sleep(2500); + }); + await PasswordTextBox.clear().then(function() { + browser.sleep(2500); + PasswordTextBox.sendKeys('EDmin123'); + browser.sleep(1000); + }); + await NextButton.click().then(function() { + browser.sleep(2500); + }); + expect(await PageValidationText.getText()).toEqual("Uh oh. Something isn't quite right. Please try again."); + await PasswordRecoveryLinkText.click().then(function() { + browser.sleep(2500); + }); + browser.getAllWindowHandles().then(function (handles) { + browser.driver.switchTo().window(handles[1]).then(async function () { + browser.sleep(5000); + expect(await browser.driver.getCurrentUrl()).toEqual('https://qa.journeysmap.com/login_recovery#/findAccount'); + browser.driver.close(); + browser.sleep(2500); + browser.driver.switchTo().window(handles[0]); + expect(await PageGreetingText.getText()).toEqual('Login and start exploring.'); + }); + }); + await CloseXIcon.click().then(function() { + browser.sleep(1000); + browser.get('https://app-qa.journeysmap.com/Journey/index.html#/login'); + browser.sleep(2500); + }); + await UserNameTextBox.sendKeys('QA_AutomatedRegression').then(function() { + browser.sleep(2500); + }); + await PasswordTextBox.sendKeys('3Dm!nAuto').then(function() { + browser.sleep(2500); + }); + /*await PasswordTextBox.clear().then(function() { + browser.sleep(2500); + PasswordTextBox.sendKeys('3Dm!nAuto'); + browser.sleep(1000); + });*/ + await NextButton.click().then(function() { browser.sleep(5000); browser.waitForAngular(); browser.getCurrentUrl(); }); - //browser.refresh();//Role Model doesn't always load properly EDM-1603 - //browser.driver.navigate().refresh(); expect(await JourneysGreeting.getText()).toEqual('Hi, Automated'); browser.waitForAngular(); browser.getCurrentUrl(); @@ -55,11 +112,11 @@ describe('Journeysmap script', function () { SkillsAssessmentWidget(); SkillsAssessmentResults(); - BeginCareerExploration(); MyCareersCarousel(); + //Top Career Widget EditTopCareer(); TopCareerWidget(); NearbyPlacesOccupationCard(); @@ -94,7 +151,7 @@ describe('Journeysmap script', function () { MapInteraction(); //<<<>>> - MyActivityJourneys(); + /*MyActivityJourneys(); SurveyMetrics(); Logins(); InstitutionMetrics(); @@ -257,8 +314,8 @@ function MyProgressWidget() { expect(await FirstOccupationCardTitle.getText()).toEqual('Administrative Law Judges, Adjudicators, and Hearing Officers'); expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('At a'); expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('Glance'); - expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Interest'); - expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); + //expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Interest'); EDM-1726 + //expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); EDM-1726 expect(await SecondOccupationCardTitle.getText()).toEqual('Administrative Services Managers'); expect(await ThirdOccupationCardTitle.getText()).toEqual('Administrative Services Managers'); browser.executeScript('window.scrollTo(0, 0);').then(function() { @@ -529,8 +586,8 @@ function InterestSurveyResultsWidget() { expect(await FirstOccupationCardTitle.getText()).toEqual('Administrative Law Judges, Adjudicators, and Hearing Officers'); expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('At a'); expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('Glance'); - expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Interest');//loading issue, not consistent - expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit');//loading issue, not consistent + //expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Interest');//loading issue, not consistent EDM-1726 + //expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit');//loading issue, not consistent EDM-1726 expect(await SecondOccupationCardTitle.getText()).toEqual('Administrative Services Managers'); expect(await ThirdOccupationCardTitle.getText()).toEqual('Administrative Services Managers'); browser.executeScript('window.scrollTo(0, 610);').then(function() { @@ -667,7 +724,7 @@ function InterestSurveyResultsClusters() { browser.actions().mouseMove(SecondAtAGlanceIcon).perform().then(function() { browser.sleep(2500); }); - expect(await BestMatchIcon.getText()).toContain('Best Fit'); + //expect(await BestMatchIcon.getText()).toContain('Best Fit'); EDM-1726 await AtAGlanceIcon.click().then(function() { browser.sleep(2500); }); @@ -1187,7 +1244,7 @@ function SkillsAssessmentWidget() { browser.sleep(10000); expect(await SkillsAssessmentResultPageTitle.getText()).toEqual('Skills Assessment Result'); expect(await YourTop3SkillsWidgetTitle.getText()).toEqual('Your top 3 skills View All'); - expect(await FitHeader.getText()).toEqual('BEST FIT'); + //expect(await FitHeader.getText()).toEqual('BEST FIT'); EDM-1726 expect(await BestFitHeaderOne.getText()).toEqual('Building and Construction'); expect(await DescriptionOne.getText()).toContain('Knowledge of materials, methods, and the tools involved in the construction or repair of houses, buildings, or other structures such as highways and roads.'); expect(await BestFitHeaderTwo.getText()).toEqual('Foreign Language'); @@ -1214,7 +1271,7 @@ function SkillsAssessmentWidget() { expect(await DescriptionThree.getText()).toContain('Knowledge of administrative and clerical procedures and systems such as word processing, managing files and records, stenography and transcription, designing forms, and other office procedures and terminology.'); await CarrouselRightScroll.click(); browser.sleep(2500); - expect(await FitHeader.getText()).toEqual('BEST FIT'); + //expect(await FitHeader.getText()).toEqual('BEST FIT'); EDM-1726 await DashboardHeaderLink.click().then(function() { browser.sleep(5000); }); @@ -1267,7 +1324,7 @@ function SkillsAssessmentResults() { browser.sleep(5000); }); expect(await SkillsAssessmentWidgetTitle.getText()).toEqual('Skills Assessment Results'); - expect(await BestFitHeader.getText()).toEqual('BEST FIT'); + //expect(await BestFitHeader.getText()).toEqual('BEST FIT'); EDM-1726 expect(await SkillsResultsOneTitle.getText()).toEqual('Building and Construction'); expect(await SkillsResultsOneDescription.getText()).toEqual('Knowledge of materials, methods, and the tools involved in the construction or repair of houses, buildings, or other structures such as highways and roads.'); expect(await SkillsResultsTwoTitle.getText()).toEqual('Foreign Language'); @@ -1281,7 +1338,7 @@ function SkillsAssessmentResults() { await ViewAllLink.click().then(function() { browser.sleep(1000); }); - expect(await BestFitDivHeader.getText()).toEqual('BEST FIT'); + //expect(await BestFitDivHeader.getText()).toEqual('BEST FIT'); EDM-1726 expect(await DivHeaderOne.getText()).toEqual('Building and Construction'); expect(await DivDescriptionOne.getText()).toContain('Knowledge of materials, methods, and the tools involved in the construction or repair of houses, buildings, or other structures such as highways and roads.'); expect(await DivHeaderTwo.getText()).toEqual('Foreign Language'); @@ -1498,7 +1555,7 @@ function MyCareersCarousel() { expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('At a'); expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('Glance'); expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Interest'); - expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); + //expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); EDM-1726 expect(await SecondOccupationCardTitle.getText()).toEqual('Business Intelligence Analysts'); expect(await ThirdOccupationCardTitle.getText()).toEqual('Airfield Operations Specialists'); await RemoveRightFilterButton.click().then(function() { @@ -1508,7 +1565,7 @@ function MyCareersCarousel() { expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('At a'); expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('Glance'); expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Interest'); - expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); + //expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); EDM-1726 expect(await SecondOccupationCardTitle.getText()).toEqual('Airfield Operations Specialists'); expect(await ThirdOccupationCardTitle.getText()).toEqual('Business Intelligence Analysts'); await FollowFirstOccupationCardIcon.click().then(function() { @@ -1528,7 +1585,7 @@ function MyCareersCarousel() { expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('At a'); expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('Glance'); expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Interest'); - expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); + //expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); EDM-1726 expect(await SecondOccupationCardTitle.getText()).toEqual('Administrative Services Managers'); expect(await ThirdOccupationCardTitle.getText()).toEqual('Administrative Services Managers'); await RemoveLastFilterButton.click().then(function() { @@ -1538,7 +1595,7 @@ function MyCareersCarousel() { expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('At a'); expect(await FirstOccupationCardAtAGlanceIcon.getText()).toContain('Glance'); expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Interest'); - expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); + //expect(await FirstOccupationCardBestFitIcon.getText()).toContain('Best Fit'); EDM-1726 expect(await SecondOccupationCardTitle.getText()).toEqual('Administrative Services Managers'); expect(await ThirdOccupationCardTitle.getText()).toEqual('Administrative Services Managers'); browser.sleep(2500); @@ -3508,10 +3565,10 @@ function MyJourneysPage() { var RemoveJourneyButton = element(by.css('#saveJourneyButton')); var EC = protractor.ExpectedConditions; var BackLink = element(by.css('.btn-primary-back-mod')); - var PersistOnMapRadioButton = element(by.name('#e0049880-9613-4fd5-9ed2-eb468cdc2e55 input')); + var PersistOnMapRadioButton = element(by.css('#\\30 9731631-9cb7-449b-8a51-58d7e730e31b input')); await MyJourneysHeaderLink.click().then(function() { - browser.sleep(10000); + browser.sleep(5000); }); await expect(PageTitle.getText()).toEqual('My Saved Journeys'); expect(await PageSubTitle.getText()).toEqual('Select a Journey to show it on the map'); @@ -3526,9 +3583,9 @@ function MyJourneysPage() { expect(await SelectedJourneyBubbleEightOne.getText()).toEqual('Business'); expect(await SelectedJourneyBubbleEightTwo.getText()).toEqual('Administratio'); expect(await SelectedJourneyBubbleEightThree.getText()).toEqual('n B.A./B.S.'); - expect(await SelectedJourneyBubbleNineOne.getText()).toEqual('National'); - expect(await SelectedJourneyBubbleNineTwo.getText()).toEqual('Chief'); - expect(await SelectedJourneyBubbleNineThree.getText()).toEqual('Engineer/Assi...'); + expect(await SelectedJourneyBubbleNineOne.getText()).toEqual('Certified'); + expect(await SelectedJourneyBubbleNineTwo.getText()).toEqual('Audio'); + expect(await SelectedJourneyBubbleNineThree.getText()).toEqual('Engineer'); expect(await SelectedJourneyBubbleTenOne.getText()).toEqual('Administrativ'); expect(await SelectedJourneyBubbleTenTwo.getText()).toEqual('e Services'); expect(await SelectedJourneyBubbleTenThree.getText()).toEqual('Managers'); @@ -3569,7 +3626,7 @@ function MyJourneysPage() { await SelectedJourneyRightArrow.click().then(function() { browser.sleep(2500); }); - expect(await SelectedJourneySubTitle.getText()).toEqual('National Chief Engineer/Assistant Engineer UFIV'); + expect(await SelectedJourneySubTitle.getText()).toEqual('Certified Audio Engineer'); await SelectedJourneyRightArrow.click().then(function() { browser.sleep(2500); }); @@ -3617,7 +3674,7 @@ function MyJourneysPage() { browser.sleep(2500); }); browser.waitForAngular(); - browser.wait(EC.visibilityOf(Select1stJourneyTitle)); + browser.wait(EC.invisibilityOf(Select1stJourneyTitle)); browser.waitForAngular(); browser.getCurrentUrl(); }); @@ -3628,7 +3685,7 @@ function MapInteraction() { var MapHeaderLink = element(by.css('.ng-scope:nth-child(2) .span-navbar-hover')); var MapSearchTextBox = element(by.css('#searchBox')); var MapSearchIcon = element(by.css('.glyphicon-search')); - var CollegeTabLink = element(by.css('#tab-item-1 > .ng-binding')); + var CollegeTabLink = element(by.xpath('//md-tab-item[2]/span'));//css('#tab-item-1 > .ng-binding')); var CollegePath = element(by.css('#tab-content-1 #searchitem0 .ng-scope > div > .side-bar-ancestory-txt')); var CollegeTitle = element(by.css('#tab-content-1 #searchitem0 .side-bar-child-text:nth-child(2)')); var CollegeDescription = element(by.css('#tab-content-1 #searchitem0 .sidebarDescription')); @@ -3667,7 +3724,7 @@ function MapInteraction() { var HideJourneyButton = element(by.css('#persistJourneyButton > .ng-binding')); var MapZoomInIcon = element(by.css('.glyphicon-plus')); var ExpandIconDetailPanel = element(by.css('div:nth-child(2) > .back-btn-mod')); - var BackLink = element(by.css('div:nth-child(2) > .sidebarBackTxt')); + var BackLink = element(by.css('.sideBarSearchBarContainer > div:nth-child(1) > div:nth-child(1) > div')); var ItemOnePath = element(by.css('#searchitem0 .ng-scope > div > .side-bar-ancestory-txt')); var ItemOneTitle = element(by.css('#searchitem0 .side-bar-child-text')); var ItemDescription = element(by.css('.sidebarDescription')); @@ -3696,7 +3753,7 @@ function MapInteraction() { }); await MapSearchTextBox.sendKeys('Software Quality Assurance Analyst'); await MapSearchIcon.click().then(function() { - browser.sleep(5000); + browser.sleep(10000); }); await CollegeTabLink.click().then(function() { browser.sleep(2500); @@ -3820,7 +3877,7 @@ function MapInteraction() { await ItemOneTitle.click().then(function() { browser.sleep(2500); }); - expect(await ItemOnePath.getText()).toEqual('20IT > Programming & Software Development >'); + expect(await ItemOnePath.getText()).toEqual('IT > Programming & Software Development >'); expect(await ItemOneTitle.getText()).toEqual('Software Quality Assurance Engineers and Testers'); expect(await ItemDescription.getText()).toEqual('Develop and execute software test plans in order to identify software problems and their causes.'); expect(await ItemOneDegreeHeader.getText()).toEqual('TYPICAL DEGREE'); @@ -3897,31 +3954,31 @@ function MyActivityJourneys() { }); expect(await MySavedJourneysTitle.getText()).toEqual('My Saved Journeys'); expect(await ViewOnMapText.getText()).toEqual('Select a Journey to show it on the map'); - expect(await MySavedJourneyOne.getText()).toEqual('6 to Administrative Services Managers through Business Administration B.A./B.S.'); + expect(await MySavedJourneyOne.getText()).toEqual('11 to Fitness and Wellness Coordinators through M.U.R.P.'); expect(await MySavedJourneyTwo.getText()).toEqual('8 to Airfield Operations Specialists through College'); expect(await MySavedJourneyThree.getText()).toEqual('10 to Computer and Information Systems Managers through Computer Security Graduate Certificate'); expect(await MySavedJournyeFour.getText()).toEqual('2 to Natural Sciences Managers through Geology M.A.T./M.S.T.'); await BackLink.click().then(function() { browser.sleep(5000); }); - expect(await JourneyTitleOne.getText()).toEqual('6 to Administrative Services Managers through Business Administration B.A./B.S.'); + expect(await JourneyTitleOne.getText()).toEqual('11 to Fitness and Wellness Coordinators through M.U.R.P.'); await JourneyLearnMoreLinkOne.click().then(function() { browser.sleep(5000); }); - expect(await JourneyLearnMoreTitle.getText()).toEqual('6 to Administrative Services Managers through Business Administration B.A./B.S.'); + expect(await JourneyLearnMoreTitle.getText()).toEqual('11 to Fitness and Wellness Coordinators through M.U.R.P.'); await BackLink.click().then(function() { browser.sleep(5000); }); - expect(await JourneyProgressStepsOne.getText()).toContain('10 steps (0 Complete)'); + expect(await JourneyProgressStepsOne.getText()).toContain('7 steps (0 Complete)'); //expect(await JourneyTitleTwo.getText()).toEqual(''); expect(await JourneyLearnMoreLinkTwo.getText()).toEqual('Learn More'); expect(await JourneyProgressStepsTwo.getText()).toContain('4 steps (0 Complete)'); //expect(await JourneyTitleThree.getText()).toEqual(''); expect(await JourneyLearnMoreLinkThree.getText()).toEqual('Learn More'); - expect(await JourneyProgressStepsThree.getText()).toContain('7 steps (0 Complete)'); + expect(await JourneyProgressStepsThree.getText()).toContain('5 steps (0 Complete)'); //expect(await JourneyTitleFour.getText()).toEqual(''); expect(await JourneyLearnMoreLinkFour.getText()).toEqual('Learn More'); - expect(await JourneyProgressStepsFour.getText()).toContain('5 steps (0 Complete)'); + expect(await JourneyProgressStepsFour.getText()).toContain('13 steps (0 Complete)'); browser.executeScript('window.scrollTo(0, 235);').then(function() { browser.sleep(1000); }); @@ -4069,6 +4126,7 @@ function Logins() { var November2019 = element(by.css('#loginMonthPicker > .month-picker-lbl')); var LastLoggedInDivHeader = element(by.css('.row:nth-child(2) > .col-lg-3')); var TotalLoginsDivHeader = element(by.css('.row:nth-child(3) > .col-lg-3')); + var TotalLoginsDivData = element(by.css('.row:nth-child(3) > .col-lg-9')); var FrequencyOfLoginsDivHeader = element(by.css('.login-display-row:nth-child(4) > .col-xs-12')); var FavoriteDaysToLoginDivHeader = element(by.css('.col-md-8 > div:nth-child(1)')); var FavoriteDayDivHeaderOne = element(by.css('.col-md-8 > .ng-scope:nth-child(2) > .ng-binding')); @@ -4107,7 +4165,6 @@ function Logins() { var November28Header = element(by.css('text:nth-child(58)')); var November29Header = element(by.css('text:nth-child(59)')); var November30Header = element(by.css('text:nth-child(60)')); - var MonthlyTuesdayHeader = element(by.css('.day-selecter-container')); var MonthlyTuesdayCeiling = element(by.css('#hourChart > text:nth-child(53)')); var MonthlyTuesday12amHeader = element(by.css('text:nth-child(25)')); var MonthlyTuesday3amHeader = element(by.css('text:nth-child(28)')); @@ -4127,7 +4184,6 @@ function Logins() { expect(await LastLoggedInHeader.getText()).toEqual('Last Logged In:'); expect(await MonthOfHeader.getText()).not.toEqual('Month of November, 2019'); expect(await TotalLoginsHeader.getText()).toEqual('Total Logins:'); - expect(await WeeklyCeilingLogin.getText()).toEqual('50'); expect(await SundayHeader.getText()).toEqual('S'); expect(await MondayHeader.getText()).toEqual('M'); browser.actions().mouseMove(MondayData).perform().then(function() { @@ -4160,6 +4216,7 @@ function Logins() { expect(await LastLoggedInHeader.getText()).toEqual('Last Logged In:'); expect(await MonthOfHeader.getText()).not.toEqual('Month of November, 2019'); expect(await TotalLoginsHeader.getText()).toEqual('Total Logins:'); + expect(await WeeklyCeilingLogin.getText()).toEqual('132'); expect(await TotalLoginsData.getText()).toEqual('404'); expect(await MondayHeader.getText()).toEqual('M'); browser.actions().mouseMove(MondayData).perform().then(function() { @@ -4184,7 +4241,7 @@ function Logins() { expect(await November2019.getText()).toEqual('11/2019'); expect(await LastLoggedInDivHeader.getText()).toEqual('Last Logged In:'); expect(await TotalLoginsDivHeader.getText()).toEqual('Total Logins:'); - + expect(await TotalLoginsDivData.getText()).toEqual('404'); expect(await FrequencyOfLoginsDivHeader.getText()).toEqual('Frequency of logins for the month of November 2019:'); expect(await FavoriteDaysToLoginDivHeader.getText()).toEqual('Favorite days to login'); expect(await FavoriteDayDivHeaderOne.getText()).toEqual('Tuesday - 132'); @@ -4227,7 +4284,6 @@ function Logins() { expect(await November28Header.getText()).toEqual('28'); expect(await November29Header.getText()).toEqual('29'); expect(await November30Header.getText()).toEqual('30'); - expect(await MonthlyTuesdayHeader.getText()).toContain('Wednesday'); expect(await MonthlyTuesdayCeiling.getText()).toEqual('24'); expect(await MonthlyTuesday12amHeader.getText()).toEqual('12a'); expect(await MonthlyTuesday3amHeader.getText()).toEqual('3a'); @@ -4757,7 +4813,7 @@ function OccupationsOfInterest() { var OccupationsOfInterestViewAllLink = element(by.css('#occupationVisitedId .text-color-7a')); var OccupationsOfInterestTitle = element(by.css('.col-sm-12 > .ng-binding')); var OccupationsOfInterestFirstCard = element(by.id('territoryCardMobileTitle')); - var FirstOccupationCardDescription = element(by.css('#\\32 26a35d5-9f4d-4f3e-8327-bce9c771d0e6 > div > table > tbody > tr:nth-child(3) > td > div > div:nth-child(2) > territory-card-at-a-glance-back > div > div.territoryCardDescriptionText.ng-binding')); + var FirstOccupationCardDescription = element(by.css('#\\35 d1377f6-b0bc-4750-945e-1f0d12df3807 > div > table > tbody > tr:nth-child(3) > td > div > div:nth-child(2) > territory-card-at-a-glance-back > div > div.territoryCardDescriptionText.ng-binding')); var OccupationsOfInterestXCloseLink = element(by.css('.default-color4a')); browser.executeScript('window.scrollTo(0, document.body.scrollHeight);').then(function() { @@ -4782,7 +4838,7 @@ function OccupationsOfInterest() { await OccupationsOfInterestFirstCard.click().then(function() { browser.sleep(2500); }); - expect(await FirstOccupationCardDescription.getText()).toEqual('Develop, create, and modify general computer applications software or specialized utility programs. Analyze user needs and develop software solutions. Design software or customize software for client use with the aim of optimizing operational efficiency. May analyze and design databases within an application area, working individually or coordinating database development as part of a team. May supervise computer programmers.'); + expect(await FirstOccupationCardDescription.getText()).toEqual('Plan, direct, or coordinate activities in such fields as electronic data processing, information systems, systems analysis, and computer programming.'); await OccupationsOfInterestXCloseLink.click().then(function() { browser.sleep(2500); });