Files
EdGateAutomatedRegression/skillsMatcherResultsWidget_spec.js
2020-10-07 17:27:06 -07:00

737 lines
65 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
//skillsMatcherResultsWidget_spec.js
describe('Skills Matcher Results Widget Script', function () {
//login-journeysmap landing page
var UserNameTextBox = element(by.css('#txtU'));
var PasswordTextBox = element(by.css('#txtP'));
//Open browser
browser.get(browser.params.login);
it('should have a title', async function () {
await expect(browser.getTitle()).toEqual('Login');
});
//Sign In
SignIn(UserNameTextBox, PasswordTextBox);
function SignIn(UserNameTextBox, PasswordTextBox) {
it('SignIn, should sign into journeysmap.com', async function () {
var PageGreetingText = element(by.css('td > div > div:nth-child(1)'));
var NextButton = element(by.css('.btn'));
var JourneysGreeting = element(by.css('.dropdown'));
expect(await PageGreetingText.getText()).toEqual('Login and start exploring.');
browser.sleep(2500);
await UserNameTextBox.sendKeys(browser.params.username).then(function() {
browser.sleep(2500);
});
await PasswordTextBox.sendKeys('3Dm!nAuto').then(function() {
browser.sleep(2500);
});
await NextButton.click().then(function() {
browser.sleep(5000);
browser.waitForAngular();
browser.getCurrentUrl();
});
expect(await JourneysGreeting.getText()).toEqual('Hi, Automated');
browser.waitForAngular();
browser.getCurrentUrl();
});
}
//<<<<DASHBOARD>>>>
SkillsMatcherResultsWidget();
SkillsMatcherRetake();
SkillsMatcherCareerExploration();
InterestSurveyResultsCreateJourney();
DeleteCreatedJourney();
//Sign Out*/
SignOut();
});
function SkillsMatcherResultsWidget() {
it(': SkillsMatcherResultsWidget, should validate Skills Matcher Results widget', async function () {
var SkillsMatcherResultsWidgetTitle = element(by.css('.bigScreenHeader'));
var BestFitSubHeader = element(by.css('div:nth-child(2) > b'));
var SkillsResultsOneTitle = element(by.css('.ng-scope:nth-child(4) > div > div > .ng-binding:nth-child(1)'));
var SkillsResultsOneDescription = element(by.css('.ng-scope:nth-child(4) .skillProfilerResultTruncateText'));
var SkillsResultsTwoTitle = element(by.css('.skillProfilerResultsSpacing:nth-child(5) > div > div > .ng-binding'));
var SkillsResultsTwoDescription = element(by.css('.ng-scope:nth-child(5) .skillProfilerResultTruncateText'));
var SkillsResultsThreeTitle = element(by.css('.ng-scope:nth-child(6) > div > div > .ng-binding'));
var SkillsResultsThreeDescription = element(by.css('.ng-scope:nth-child(6) .skillProfilerResultTruncateText'));
var SkillsResultsIcon = element(by.css('div:nth-child(7) > div:nth-child(1) > .hideIconLabels'));
var SkillsRetakeIcon = element(by.css('div:nth-child(7) > div:nth-child(2) > .hideIconLabels'));
browser.executeScript('window.scrollTo(0, 592);').then(function() {
browser.sleep(5000);
});
expect(await SkillsMatcherResultsWidgetTitle.getText()).toEqual('Skills Matcher Results');
expect(await BestFitSubHeader.getText()).toEqual('BEST FIT');
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');
expect(await SkillsResultsTwoDescription.getText()).toEqual('Knowledge of the structure and content of a foreign (non-English) language including the meaning and spelling of words, rules of composition and grammar, and pronunciation.');
expect(await SkillsResultsThreeTitle.getText()).toEqual('Management of Financial Resources');
expect(await SkillsResultsThreeDescription.getText()).toEqual('Making spending decisions and keeping track of what is spent.');
expect(await SkillsResultsIcon.getText()).toEqual('Results');
expect(await SkillsRetakeIcon.getText()).toEqual('Retake');
});
}
function SkillsMatcherRetake() {
it(': SkillsMatcherRetake, should retake Skills Matcher', async function () {
var InterestRetakeLink = element(by.css('div:nth-child(2) > .fa-tasks'));
var SkillsMatcherPageTitle = element(by.css('.jrnys_lead-body-copy'));
var SkillsQuestion = element(by.css('.questionText > .ng-binding:nth-child(1)'));
var SkillsSubQuestion = element(by.css('.questionText > .ng-binding:nth-child(2)'));
var BeginnerIcon = element(by.id('emoji_0_0'));
var BasicIcon = element(by.id('emoji_0_1'));
var SkilledIcon = element(by.id('emoji_0_2'));
var AdvancedIcon = element(by.id('emoji_0_3'));
var ExpertIcon = element(by.id('emoji_0_4'));
var CancelAssessment = element(by.css('.btn-md'));
var PreviousQuestion = element(by.linkText('< Previous Question'));
var SkillsMatcherResultPageTitle = element(by.css('.surveyContainer > .col-xs-offset-1'));
var YourTop3SkillsWidgetTitle = element(by.css('.fullHeight > .jrnys_lead-body-copy'));
var BestFitHeader = element(by.css('.ng-scope:nth-child(1) > .row > div > div > .jrnys_lead-body-copy'));
var BestFitSubTextHeaderOne = element(by.css('.ng-scope:nth-child(1) > .row > div > div > .ng-binding:nth-child(2) > .ng-binding'));
var BestFitSubTextOne = element(by.css('.ng-scope:nth-child(1) > .row > div > div > .ng-binding:nth-child(2)'));
var BestFitSubTextHeaderTwo = element(by.css('.ng-scope:nth-child(1) > .row > div > div > .ng-binding:nth-child(3) > .ng-binding'));
var BestFitSubTextTwo = element(by.css('.ng-scope:nth-child(1) > .row > div > div > .ng-binding:nth-child(3)'));
var BestFitSubTextHeaderThree = element(by.css('.ng-scope:nth-child(1) > .row > div > div > .ng-binding:nth-child(4) > .ng-binding'));
var BestFitSubTextThree = element(by.css('.ng-scope:nth-child(1) > .row > div > div > .ng-binding:nth-child(4)'));
var GreatFitHeader = element(by.css('.ng-scope:nth-child(2) > .row > div > div > .jrnys_lead-body-copy'));
var GreatFitSubTextHeaderOne = element(by.css('.ng-scope:nth-child(2) > .row > div > div > .ng-binding:nth-child(2) > .ng-binding'));
var GreatFitSubTextOne = element(by.css('.ng-scope:nth-child(2) > .row > div > div > .ng-binding:nth-child(2)'));
var GreatFitSubTextHeaderTwo = element(by.css('.ng-scope:nth-child(2) > .row > div > div > .ng-binding:nth-child(3) > .ng-binding'));
var GreatFitSubTextTwo = element(by.css('.ng-scope:nth-child(2) > .row > div > div > .ng-binding:nth-child(3)'));
var GreatFitSubTextHeaderThree = element(by.css('.ng-scope:nth-child(2) > .row > div > div > .ng-binding:nth-child(4) > .ng-binding'));
var GreatFitSubTextThree = element(by.css('.ng-scope:nth-child(2) > .row > div > div > .ng-binding:nth-child(4)'));
var GoodFitHeader = element(by.css('.ng-scope:nth-child(3) > .row > div > div > .jrnys_lead-body-copy'));
var GoodFitSubTextHeaderOne = element(by.css('.ng-scope:nth-child(3) > .row > div > div > .ng-binding:nth-child(2) > .ng-binding'));
var GoodFitSubTextOne = element(by.css('.ng-scope:nth-child(3) > .row > div > div > .ng-binding:nth-child(2)'));
var GoodFitSubTextHeaderTwo = element(by.css('.ng-scope:nth-child(3) > .row > div > div > .ng-binding:nth-child(3) > .ng-binding'));
var GoodFitSubTextTwo = element(by.css('.ng-scope:nth-child(3) > .row > div > div > .ng-binding:nth-child(3)'));
var GoodFitSubTextHeaderThree = element(by.css('.ng-scope:nth-child(3) > .row > div > div > .ng-binding:nth-child(4) > .ng-binding'));
var GoodFitSubTextThree = element(by.css('.ng-scope:nth-child(3) > .row > div > div > .ng-binding:nth-child(4)'));
var ViewAllLink = element(by.linkText('View All'));
var ViewAllDIVBestFitHeader = element(by.css('.row:nth-child(1) > .col-xs-10 > .jrnys_lead-body-copy'));
var ViewAllDIVBestFitSubTextHeaderOne = element(by.css('.row:nth-child(1) > .col-xs-10 > .ng-binding:nth-child(2) > .ng-binding'));
var ViewAllDIVBestFitSubTextOne = element(by.css('.row:nth-child(1) > .col-xs-10 > .ng-binding:nth-child(2)'));
var ViewAllDIVBestFitSubTextHeaderTwo = element(by.css('.row:nth-child(1) > .col-xs-10 > .ng-binding:nth-child(3) > .ng-binding'));
var ViewAllDIVBestFitSubTextTwo = element(by.css('.row:nth-child(1) > .col-xs-10 > .ng-binding:nth-child(3)'));
var ViewAllDIVBestFitSubTextHeaderThree = element(by.css('.row:nth-child(1) > .col-xs-10 > .ng-binding:nth-child(4) > .ng-binding'));
var ViewAllDIVBestFitSubTextThree = element(by.css('.row:nth-child(1) > .col-xs-10 > .ng-binding:nth-child(4)'));
var ViewAllDIVBestFitSubTextHeaderFour = element(by.css('.row:nth-child(1) .ng-binding:nth-child(5) > .ng-binding'));
var ViewAllDIVBestFitSubTextFour = element(by.css('.row:nth-child(1) .ng-binding:nth-child(5)'));
var ViewAllDIVBestFitSubTextHeaderFive = element(by.css('.row:nth-child(1) .ng-binding:nth-child(6) > .ng-binding'));
var ViewAllDIVBestFitSubTextFive = element(by.css('.row:nth-child(1) .ng-binding:nth-child(6)'));
var ViewAllDIVBestFitSubTextHeaderSix = element(by.css('.row:nth-child(1) .ng-binding:nth-child(7) > .ng-binding'));
var ViewAllDIVBestFitSubTextSix = element(by.css('.row:nth-child(1) .ng-binding:nth-child(7)'));
var ViewAllDIVBestFitSubTextHeaderSeven = element(by.css('.row:nth-child(1) .ng-binding:nth-child(8) > .ng-binding'));
var ViewAllDIVBestFitSubTextSeven = element(by.css('.row:nth-child(1) .ng-binding:nth-child(8)'));
var ViewAllDIVGreatFitHeader = element(by.css('.row:nth-child(2) .jrnys_lead-body-copy'));
var ViewAllDIVGreatFitSubTextHeaderOne = element(by.css('.row:nth-child(2) .ng-binding:nth-child(2) > .ng-binding'));
var ViewAllDIVGreatFitSubTextOne = element(by.css('.row:nth-child(2) .ng-binding:nth-child(2)'));
var ViewAllDIVGreatFitSubTextHeaderTwo = element(by.css('.row:nth-child(2) .ng-binding:nth-child(3) > .ng-binding'));
var ViewAllDIVGreatFitSubTextTwo = element(by.css('.row:nth-child(2) .ng-binding:nth-child(3)'));
var ViewAllDIVGreatFitSubTextHeaderThree = element(by.css('.row:nth-child(2) .ng-binding:nth-child(4) > .ng-binding'));
var ViewAllDIVGreatFitSubTextThree = element(by.css('.row:nth-child(2) .ng-binding:nth-child(4)'));
var ViewAllDIVGreatFitSubTextHeaderFour = element(by.css('.row:nth-child(2) .ng-binding:nth-child(5) > .ng-binding'));
var ViewAllDIVGreatFitSubTextFour = element(by.css('.row:nth-child(2) .ng-binding:nth-child(5)'));
var ViewAllDIVGreatFitSubTextHeaderFive = element(by.css('.row:nth-child(2) .ng-binding:nth-child(6) > .ng-binding'));
var ViewAllDIVGreatFitSubTextFive = element(by.css('.row:nth-child(2) .ng-binding:nth-child(6)'));
var ViewAllDIVGreatFitSubTextHeaderSix = element(by.css('.row:nth-child(2) .ng-binding:nth-child(7) > .ng-binding'));
var ViewAllDIVGreatFitSubTextSix = element(by.css('.row:nth-child(2) .ng-binding:nth-child(7)'));
var ViewAllDIVGoodFitHeader = element(by.css('.row:nth-child(3) > .col-xs-10 > .jrnys_lead-body-copy'));
var ViewAllDIVGoodFitSubTextHeaderOne = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(2) > .ng-binding'));
var ViewAllDIVGoodFitSubTextOne = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(2)'));
var ViewAllDIVGoodFitSubTextHeaderTwo = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(3) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwo = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(3)'));
var ViewAllDIVGoodFitSubTextHeaderThree = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(4) > .ng-binding'));
var ViewAllDIVGoodFitSubTextThree = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(4)'));
var ViewAllDIVGoodFitSubTextHeaderFour = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(5) > .ng-binding'));
var ViewAllDIVGoodFitSubTextFour = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(5)'));
var ViewAllDIVGoodFitSubTextHeaderFive = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(6) > .ng-binding'));
var ViewAllDIVGoodFitSubTextFive = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(6)'));
var ViewAllDIVGoodFitSubTextHeaderSix = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(7) > .ng-binding'));
var ViewAllDIVGoodFitSubTextSix = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(7)'));
var ViewAllDIVGoodFitSubTextHeaderSeven = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(8) > .ng-binding'));
var ViewAllDIVGoodFitSubTextSeven = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(8)'));
var ViewAllDIVGoodFitSubTextHeaderEight = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(9) > .ng-binding'));
var ViewAllDIVGoodFitSubTextEight = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(9)'));
var ViewAllDIVGoodFitSubTextHeaderNine = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(10) > .ng-binding'));
var ViewAllDIVGoodFitSubTextNine = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(10)'));
var ViewAllDIVGoodFitSubTextHeaderTen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(11) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(11)'));
var ViewAllDIVGoodFitSubTextHeaderEleven = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(12) > .ng-binding'));
var ViewAllDIVGoodFitSubTextEleven = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(12)'));
var ViewAllDIVGoodFitSubTextHeaderTwelve = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(13) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwelve = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(13)'));
var ViewAllDIVGoodFitSubTextHeaderThirteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(14) > .ng-binding'));
var ViewAllDIVGoodFitSubTextThirteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(14)'));
var ViewAllDIVGoodFitSubTextHeaderFourteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(15) > .ng-binding'));
var ViewAllDIVGoodFitSubTextFourteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(15)'));
var ViewAllDIVGoodFitSubTextHeaderFifteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(16) > .ng-binding'));
var ViewAllDIVGoodFitSubTextFifteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(16)'));
var ViewAllDIVGoodFitSubTextHeaderSixteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(17) > .ng-binding'));
var ViewAllDIVGoodFitSubTextSixteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(17)'));
var ViewAllDIVGoodFitSubTextHeaderSeventeen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(18) > .ng-binding'));
var ViewAllDIVGoodFitSubTextSeventeen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(18)'));
var ViewAllDIVGoodFitSubTextHeaderEighteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(19) > .ng-binding'));
var ViewAllDIVGoodFitSubTextEighteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(19)'));
var ViewAllDIVGoodFitSubTextHeaderNineteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(20) > .ng-binding'));
var ViewAllDIVGoodFitSubTextNineteen = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(20)'));
var ViewAllDIVGoodFitSubTextHeaderTwenty = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(21) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwenty = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(21)'));
var ViewAllDIVGoodFitSubTextHeaderTwentyOne = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(22) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwentyOne = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(22)'));
var ViewAllDIVGoodFitSubTextHeaderTwentyTwo = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(23) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwentyTwo = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(23)'));
var ViewAllDIVGoodFitSubTextHeaderTwentyThree = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(24) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwentyThree = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(24)'));
var ViewAllDIVGoodFitSubTextHeaderTwentyFour = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(25) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwentyFour = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(25)'));
var ViewAllDIVGoodFitSubTextHeaderTwentyFive = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(26) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwentyFive = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(26)'));
var ViewAllDIVGoodFitSubTextHeaderTwentySix = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(27) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwentySix = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(27)'));
var ViewAllDIVGoodFitSubTextHeaderTwentySeven = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(28) > .ng-binding'));
var ViewAllDIVGoodFitSubTextTwentySeven = element(by.css('.row:nth-child(3) > .col-xs-10 > .ng-binding:nth-child(28)'));
var ViewAllDIVXCloseIcon = element(by.css('.close'));
var ExploreCareersButton = element(by.css('div:nth-child(2) > .btn'));
browser.executeScript('window.scrollTo(0, 592);').then(function() {
browser.sleep(2500);
});
await InterestRetakeLink.click().then(function() {
browser.sleep(5000);
});
expect(await SkillsMatcherPageTitle.getText()).toEqual('Skills Matcher');
expect(await SkillsQuestion.getText()).toEqual('Administration and Management');
expect(await SkillsSubQuestion.getText()).toEqual('How much do you know about business planning and leadership?');
expect(await CancelAssessment.getText()).toEqual('Cancel Assessment');
await SkilledIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Biology');
expect(await SkillsSubQuestion.getText()).toEqual('How much do you know about plant, animal and cell functions?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Body Coordination');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you coordinate moving your arms, legs, and torso together?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Building and Construction');
expect(await SkillsSubQuestion.getText()).toEqual('How much do you know about construction materials, methods, and tools?');
await AdvancedIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Chemistry');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know chemistry?');
await SkilledIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Clerical');
expect(await SkillsSubQuestion.getText()).toEqual('How much do you know about administrative tasks and processes?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Complex Problem Solving');
expect(await SkillsSubQuestion.getText()).toEqual('How good are you at figuring out the best way to solve a problem?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Computers and Electronics');
expect(await SkillsSubQuestion.getText()).toEqual('How effective are you at using electronic equipment?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Customer and Personal Service');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know how to handle customer needs and resolve service problems?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Economics and Accounting');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know banking and financial systems?');
await AdvancedIcon.click();
browser.sleep(2500);
await PreviousQuestion.click();
browser.sleep(2500);
expect(await SkillsQuestion.getText()).toEqual('Economics and Accounting');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know banking and financial systems?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Fine Arts');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know the theory and techniques of an art form such as music, painting, drama, or other?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Foreign Language');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know a foreign language?');
await AdvancedIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Helping People');
expect(await SkillsSubQuestion.getText()).toEqual('How good are you at understanding how to help people?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Instructing');
expect(await SkillsSubQuestion.getText()).toEqual('How skilled are you at teaching people how to do something?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Management of Financial Resources');
expect(await SkillsSubQuestion.getText()).toEqual('What level of financial decision-maker are you?');
await ExpertIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Mathematics');
expect(await SkillsSubQuestion.getText()).toEqual('What is your level of math skill?');
await SkilledIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Mechanical');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you design, use, repair, and maintain machines?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Medicine and Dentistry');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know how to provide health care?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Memorization');
expect(await SkillsSubQuestion.getText()).toEqual('How good is your memory?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Monitoring');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you assess your or others’ work?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Negotiation');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you persuade others to see different points of view or compromise?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Operations Analysis');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you analyze needs and requirements, then make a plan that meets them?');
await AdvancedIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Personnel and Human Resources');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know the principles and procedures for recruiting, hiring, and training employees?');
await AdvancedIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Production and Processing');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you oversee manufacturing and distribution processes?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Programming');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you write computer programs?');
await AdvancedIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Psychology');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know the methods of research, assessment, and treatment of human behavior?');
await SkilledIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Public Safety and Security');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know the equipment, policies, procedures, and strategies used to promote security operations?');
await SkilledIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Quality Control Analysis');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you develop and use testing processes?');
await AdvancedIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Repairing');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you repair machines or systems using the needed tools?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Sales and Marketing');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you perform marketing strategies and tactics?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Science');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you use scientific rules and methods to solve problems?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Sociology and Anthropology');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know the theories of group behavior, societal trends and influences, and human culture?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Speaking');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you convey information when you speak?');
await SkilledIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Systems Analysis');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you analyze systems?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Teaching and Course Design');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know the principles and methods of instruction?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Telecommunications');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you understand telecom systems?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Therapy and Counseling');
expect(await SkillsSubQuestion.getText()).toEqual('How well do you know the principles and methods used in counseling?');
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Time Management');
expect(await SkillsSubQuestion.getText()).toEqual("How well do you manage your and others' time?");
await BasicIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Troubleshooting');
expect(await SkillsSubQuestion.getText()).toEqual('How well can you identify and fix problems in machines or technology?');
await BeginnerIcon.click();
expect(await SkillsQuestion.getText()).toEqual('Writing');
expect(await SkillsSubQuestion.getText()).toEqual("How well does your writing effectively communicate to an audience's particular need?");
await BeginnerIcon.click();
browser.sleep(10000);
//Skills Matcher Results Page
expect(await SkillsMatcherResultPageTitle.getText()).toEqual('Skills Matcher Results');
expect(await YourTop3SkillsWidgetTitle.getText()).toEqual('Your Top 3 Skills View All');
expect(await BestFitHeader.getText()).toEqual('BEST FIT');
expect(await BestFitSubTextHeaderOne.getText()).toEqual('Building and Construction');
expect(await BestFitSubTextOne.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 BestFitSubTextHeaderTwo.getText()).toEqual('Foreign Language');
expect(await BestFitSubTextTwo.getText()).toContain('Knowledge of the structure and content of a foreign (non-English) language including the meaning and spelling of words, rules of composition and grammar, and pronunciation.');
expect(await BestFitSubTextHeaderThree.getText()).toEqual('Management of Financial Resources');
expect(await BestFitSubTextThree.getText()).toContain('Making spending decisions and keeping track of what is spent.');
expect(await GreatFitHeader.getText()).toEqual('GREAT FIT');
expect(await GreatFitSubTextHeaderOne.getText()).toEqual('Administration and Management');
expect(await GreatFitSubTextOne.getText()).toContain('Knowledge of business and management principles involved in strategic planning, resource allocation, human resources modeling, leadership technique, production methods, and coordination of people and resources.');
expect(await GreatFitSubTextHeaderTwo.getText()).toEqual('Chemistry');
expect(await GreatFitSubTextTwo.getText()).toContain('Knowledge of the chemical composition, structure, and properties of substances and of the chemical processes and transformations that they undergo. This includes uses of chemicals and their interactions, danger signs, production techniques, and disposal methods.');
expect(await GreatFitSubTextHeaderThree.getText()).toEqual('Mathematics');
expect(await GreatFitSubTextThree.getText()).toContain('Using math to solve problems.');
expect(await GoodFitHeader.getText()).toEqual('GOOD FIT');
expect(await GoodFitSubTextHeaderOne.getText()).toEqual('Biology');
expect(await GoodFitSubTextOne.getText()).toContain('Knowledge of plant and animal organisms, their tissues, cells, functions, interdependencies, and interactions with each other and the environment.');
expect(await GoodFitSubTextHeaderTwo.getText()).toEqual('Body Coordination');
expect(await GoodFitSubTextTwo.getText()).toContain('Moving your arms, legs, and mid-section together while your whole body is moving.');
expect(await GoodFitSubTextHeaderThree.getText()).toEqual('Clerical');
expect(await GoodFitSubTextThree.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 ViewAllLink.click().then(function() {
browser.sleep(2500);
});
expect(await ViewAllDIVBestFitHeader.getText()).toEqual('BEST FIT');
expect(await ViewAllDIVBestFitSubTextHeaderOne.getText()).toEqual('Building and Construction');
expect(await ViewAllDIVBestFitSubTextOne.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 ViewAllDIVBestFitSubTextHeaderTwo.getText()).toEqual('Foreign Language');
expect(await ViewAllDIVBestFitSubTextTwo.getText()).toContain('Knowledge of the structure and content of a foreign (non-English) language including the meaning and spelling of words, rules of composition and grammar, and pronunciation.');
expect(await ViewAllDIVBestFitSubTextHeaderThree.getText()).toEqual('Management of Financial Resources');
expect(await ViewAllDIVBestFitSubTextThree.getText()).toContain('Making spending decisions and keeping track of what is spent.');
expect(await ViewAllDIVBestFitSubTextHeaderFour.getText()).toEqual('Operations Analysis');
expect(await ViewAllDIVBestFitSubTextFour.getText()).toContain('Figuring out what a product or service needs to be able to do.');
expect(await ViewAllDIVBestFitSubTextHeaderFive.getText()).toEqual('Personnel and Human Resources');
expect(await ViewAllDIVBestFitSubTextFive.getText()).toContain('Knowledge of principles and procedures for personnel recruitment, selection, training, compensation and benefits, labor relations and negotiation, and personnel information systems.');
expect(await ViewAllDIVBestFitSubTextHeaderSix.getText()).toEqual('Programming');
expect(await ViewAllDIVBestFitSubTextSix.getText()).toContain('Writing computer programs.');
expect(await ViewAllDIVBestFitSubTextHeaderSeven.getText()).toEqual('Quality Control Analysis');
expect(await ViewAllDIVBestFitSubTextSeven.getText()).toContain('Testing how well a product or service works.');
browser.actions().mouseMove(ViewAllDIVGreatFitSubTextSix).perform().then(function() {
browser.sleep(1000);
});
expect(await ViewAllDIVGreatFitHeader.getText()).toEqual('GREAT FIT');
expect(await ViewAllDIVGreatFitSubTextHeaderOne.getText()).toEqual('Administration and Management');
expect(await ViewAllDIVGreatFitSubTextOne.getText()).toContain('Knowledge of business and management principles involved in strategic planning, resource allocation, human resources modeling, leadership technique, production methods, and coordination of people and resources.');
expect(await ViewAllDIVGreatFitSubTextHeaderTwo.getText()).toEqual('Chemistry');
expect(await ViewAllDIVGreatFitSubTextTwo.getText()).toContain('Knowledge of the chemical composition, structure, and properties of substances and of the chemical processes and transformations that they undergo. This includes uses of chemicals and their interactions, danger signs, production techniques, and disposal methods.');
expect(await ViewAllDIVGreatFitSubTextHeaderThree.getText()).toEqual('Mathematics');
expect(await ViewAllDIVGreatFitSubTextThree.getText()).toContain('Using math to solve problems.');
expect(await ViewAllDIVGreatFitSubTextHeaderFour.getText()).toEqual('Psychology');
expect(await ViewAllDIVGreatFitSubTextFour.getText()).toContain('Knowledge of human behavior and performance; individual differences in ability, personality, and interests; learning and motivation; psychological research methods; and the assessment and treatment of behavioral and affective disorders.');
expect(await ViewAllDIVGreatFitSubTextHeaderFive.getText()).toEqual('Public Safety and Security');
expect(await ViewAllDIVGreatFitSubTextFive.getText()).toContain('Knowledge of relevant equipment, policies, procedures, and strategies to promote effective local, state, or national security operations for the protection of people, data, property, and institutions.');
expect(await ViewAllDIVGreatFitSubTextHeaderSix.getText()).toEqual('Speaking');
expect(await ViewAllDIVGreatFitSubTextSix.getText()).toContain('Talking to others.');
browser.actions().mouseMove(ViewAllDIVGoodFitSubTextEleven).perform().then(function() {
browser.sleep(1000);
});
expect(await ViewAllDIVGoodFitHeader.getText()).toEqual('GOOD FIT');
expect(await ViewAllDIVGoodFitSubTextHeaderOne.getText()).toEqual('Biology');
expect(await ViewAllDIVGoodFitSubTextOne.getText()).toContain('Knowledge of plant and animal organisms, their tissues, cells, functions, interdependencies, and interactions with each other and the environment.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwo.getText()).toEqual('Body Coordination');
expect(await ViewAllDIVGoodFitSubTextTwo.getText()).toContain('Moving your arms, legs, and mid-section together while your whole body is moving.');
expect(await ViewAllDIVGoodFitSubTextHeaderThree.getText()).toEqual('Clerical');
expect(await ViewAllDIVGoodFitSubTextThree.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.');
expect(await ViewAllDIVGoodFitSubTextHeaderFour.getText()).toEqual('Complex Problem Solving');
expect(await ViewAllDIVGoodFitSubTextFour.getText()).toContain('Noticing a problem and figuring out the best way to solve it.');
expect(await ViewAllDIVGoodFitSubTextHeaderFive.getText()).toEqual('Computers and Electronics');
expect(await ViewAllDIVGoodFitSubTextFive.getText()).toContain('Knowledge of circuit boards, processors, chips, electronic equipment, and computer hardware and software, including applications and programming.');
expect(await ViewAllDIVGoodFitSubTextHeaderSix.getText()).toEqual('Customer and Personal Service');
expect(await ViewAllDIVGoodFitSubTextSix.getText()).toContain('Knowledge of principles and processes for providing customer and personal services. This includes customer needs assessment, meeting quality standards for services, and evaluation of customer satisfaction.');
expect(await ViewAllDIVGoodFitSubTextHeaderSeven.getText()).toEqual('Economics and Accounting');
expect(await ViewAllDIVGoodFitSubTextSeven.getText()).toContain('Knowledge of economic and accounting principles and practices, the financial markets, banking and the analysis and reporting of financial data.');
expect(await ViewAllDIVGoodFitSubTextHeaderEight.getText()).toEqual('Fine Arts');
expect(await ViewAllDIVGoodFitSubTextEight.getText()).toContain('Knowledge of the theory and techniques required to compose, produce, and perform works of music, dance, visual arts, drama, and sculpture.');
expect(await ViewAllDIVGoodFitSubTextHeaderNine.getText()).toEqual('Helping People');
expect(await ViewAllDIVGoodFitSubTextNine.getText()).toContain('Looking for ways to help people.');
expect(await ViewAllDIVGoodFitSubTextHeaderTen.getText()).toEqual('Instructing');
expect(await ViewAllDIVGoodFitSubTextTen.getText()).toContain('Teaching people how to do something.');
expect(await ViewAllDIVGoodFitSubTextHeaderEleven.getText()).toEqual('Mechanical');
expect(await ViewAllDIVGoodFitSubTextEleven.getText()).toContain('Knowledge of machines and tools, including their designs, uses, repair, and maintenance.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwelve.getText()).toEqual('Medicine and Dentistry');
expect(await ViewAllDIVGoodFitSubTextTwelve.getText()).toContain('Knowledge of the information and techniques needed to diagnose and treat human injuries, diseases, and deformities. This includes symptoms, treatment alternatives, drug properties and interactions, and preventive health-care measures.');
expect(await ViewAllDIVGoodFitSubTextHeaderThirteen.getText()).toEqual('Memorization');
expect(await ViewAllDIVGoodFitSubTextThirteen.getText()).toContain('Remembering words, numbers, pictures, or steps.');
expect(await ViewAllDIVGoodFitSubTextHeaderFourteen.getText()).toEqual('Monitoring');
expect(await ViewAllDIVGoodFitSubTextFourteen.getText()).toContain('Keeping track of how well people and/or groups are doing in order to make improvements.');
expect(await ViewAllDIVGoodFitSubTextHeaderFifteen.getText()).toEqual('Negotiation');
expect(await ViewAllDIVGoodFitSubTextFifteen.getText()).toContain('Bringing people together to solve differences.');
expect(await ViewAllDIVGoodFitSubTextHeaderSixteen.getText()).toEqual('Production and Processing');
expect(await ViewAllDIVGoodFitSubTextSixteen.getText()).toContain('Knowledge of raw materials, production processes, quality control, costs, and other techniques for maximizing the effective manufacture and distribution of goods.');
expect(await ViewAllDIVGoodFitSubTextHeaderSeventeen.getText()).toEqual('Repairing');
expect(await ViewAllDIVGoodFitSubTextSeventeen.getText()).toContain('Repairing machines or systems using the right tools.');
expect(await ViewAllDIVGoodFitSubTextHeaderEighteen.getText()).toEqual('Sales and Marketing');
expect(await ViewAllDIVGoodFitSubTextEighteen.getText()).toContain('Knowledge of principles and methods for showing, promoting, and selling products or services. This includes marketing strategy and tactics, product demonstration, sales techniques, and sales control systems.');
expect(await ViewAllDIVGoodFitSubTextHeaderNineteen.getText()).toEqual('Science');
expect(await ViewAllDIVGoodFitSubTextNineteen.getText()).toContain('Using scientific rules and strategies to solve problems.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwenty.getText()).toEqual('Sociology and Anthropology');
expect(await ViewAllDIVGoodFitSubTextTwenty.getText()).toContain('Knowledge of group behavior and dynamics, societal trends and influences, human migrations, ethnicity, cultures and their history and origins.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwentyOne.getText()).toEqual('Systems Analysis');
expect(await ViewAllDIVGoodFitSubTextTwentyOne.getText()).toContain('Figuring out how a system should work and how changes in the future will affect it.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwentyTwo.getText()).toEqual('Teaching and Course Design');
expect(await ViewAllDIVGoodFitSubTextTwentyTwo.getText()).toContain('Knowledge of principles and methods for curriculum and training design, teaching and instruction for individuals and groups, and the measurement of training effects.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwentyThree.getText()).toEqual('Telecommunications');
expect(await ViewAllDIVGoodFitSubTextTwentyThree.getText()).toContain('Knowledge of transmission, broadcasting, switching, control, and operation of telecommunications systems.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwentyFour.getText()).toEqual('Therapy and Counseling');
expect(await ViewAllDIVGoodFitSubTextTwentyFour.getText()).toContain('Knowledge of principles, methods, and procedures for diagnosis, treatment, and rehabilitation of physical and mental dysfunctions, and for career counseling and guidance.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwentyFive.getText()).toEqual('Time Management');
expect(await ViewAllDIVGoodFitSubTextTwentyFive.getText()).toContain('Managing your time and the time of other people.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwentySix.getText()).toEqual('Troubleshooting');
expect(await ViewAllDIVGoodFitSubTextTwentySix.getText()).toContain('Figuring out what is causing equipment, machines, wiring, or computer programs to not work.');
expect(await ViewAllDIVGoodFitSubTextHeaderTwentySeven.getText()).toEqual('Writing');
expect(await ViewAllDIVGoodFitSubTextTwentySeven.getText()).toContain('Writing things for co-workers or customers.');
await ViewAllDIVXCloseIcon.click().then(function() {
browser.sleep(2500);
});
browser.executeScript('window.scrollTo(0, document.body.scrollHeight);').then(function() {
browser.sleep(1000);
});
expect(await ExploreCareersButton.getText()).toEqual('Explore Careers');
});
}
function SkillsMatcherCareerExploration() {
it(': SkillsMatcherRetake, should interact with Skills Matcher widget and validate results', async function () {
var ExploreCareersButton = element(by.css('div:nth-child(2) > .btn'));
var CareerExplortaionPageTitle = element(by.css('.col-sm-12'));
var SkillsFilterButton = element(by.css('.filter-category-on:nth-child(3)'));
var InterestsFilterButton = element(by.css('.filter-category:nth-child(4)'));
var WidgetText = element(by.css('.row > .jrnys_lead-body-copy'));
var WidgetSubText = element(by.css('span:nth-child(2)'));
var HospitalityAndTourism = element(by.css('#\\30 6927b2f-12ec-4a78-a72b-8aa6c8576788 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var HumanServices = element(by.css('#\\33 2cf59de-d8b7-463c-86a1-5a872fca4293 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var BusinessManagementAndAdministration = element(by.css('#\\35 db8efa4-0809-4e9e-8096-db5d5d1dafd5 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var Finance = element(by.css('#\\36 ad08707-5c2b-44c7-b293-015236495276 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var CyberSecurity = element(by.css('#\\37 22f5c71-9689-4f5d-817e-286843e3335a > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var CyberSecuritySelectButton = element(by.css('#\\37 22f5c71-9689-4f5d-817e-286843e3335a > #territoryCardContainer .btn'));
var CybersecurityManagementMGT = element(by.css('#\\37 087ce2a-5602-4e7a-ac42-250182301aa3 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var CybersecurityManagementMGTSelectButton = element(by.css('#\\37 087ce2a-5602-4e7a-ac42-250182301aa3 > #territoryCardContainer .btn'));
var RiskManagementRSK = element(by.css('#e727aac1-d5d9-4051-aa13-ab45854de0b8 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var ExecutiveCyberLeadershipEXL = element(by.css('#f2578611-4857-459f-8292-f2b67bbea212 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var MarketingSalesAndService = element(by.css('#\\38 d94c030-7c25-4491-8706-57a9a83a5221 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var DisabledPreviousLinkText = element(by.css('.col-xs-2:nth-child(2)'));
var NextLinkText = element(by.linkText('Next'));
var DisabledNextLinkText = element(by.css('.col-xs-2:nth-child(3)'));
var ClusterLinkText = element(by.linkText('Clusters'));
var PathwaysLinkText = element(by.linkText('Pathways'));
var CommunicationsSecurityCOMSECManager = element(by.css('.territoryCardTitleText > .ng-binding'));
var CommunicationsSecurityCOMSECManagerLearnMoreIcon = element(by.css('.territoryCardActionBarItemContainer:nth-child(1) > .territoryCardActionBarText'));
var CommunicationsSecurityCOMSECManagerMapIcon = element(by.css('.territoryCardActionBarItemContainer:nth-child(2) > .territoryCardActionBarText'));
var CommunicationsSecurityCOMSECManagerJourneymanIcon = element(by.css('.territoryCardActionBarText:nth-child(3)'));
var CommunicationsSecurityCOMSECManagerVideoIcon = element(by.css('.territoryCardActionBarItemContainer:nth-child(4) > .territoryCardActionBarText'));
await ExploreCareersButton.click().then(function() {
browser.sleep(2500);
});
expect(SkillsFilterButton.getCssValue('background-color')).toBe('rgba(26, 188, 156, 1)'); //journey green - active
expect(await SkillsFilterButton.getText()).toEqual('Skills');
expect(InterestsFilterButton.getCssValue('background-color')).toBe('rgba(60, 162, 223, 1)'); //blue - non active
expect(await InterestsFilterButton.getText()).toEqual('Interests');
expect(await CareerExplortaionPageTitle.getText()).toEqual('Career Exploration');
expect(await WidgetText.getText()).toEqual('Clusters');
expect(await WidgetSubText.getText()).toEqual('To start your career exploration, select a cluster below.');
expect(await HospitalityAndTourism.getText()).toEqual('Hospitality and Tourism');
expect(await HumanServices.getText()).toEqual('Human Services');
expect(await BusinessManagementAndAdministration.getText()).toEqual('Business Management & Administration');
browser.executeScript('window.scrollTo(0, document.body.scrollHeight);').then(function() {
browser.sleep(1000);
});
expect(await Finance.getText()).toEqual('Finance');
expect(await CyberSecurity.getText()).toEqual('Cyber Security');
expect(await MarketingSalesAndService.getText()).toEqual('Marketing, Sales & Service');
expect(await DisabledPreviousLinkText.getText()).toEqual('Previous');
expect(await NextLinkText.getText()).toEqual('Next');
await CyberSecuritySelectButton.click().then(function() {
browser.sleep(2500);
});
expect(SkillsFilterButton.getCssValue('background-color')).toBe('rgba(26, 188, 156, 1)'); //journey green - active
expect(await SkillsFilterButton.getText()).toEqual('Skills');
expect(InterestsFilterButton.getCssValue('background-color')).toBe('rgba(60, 162, 223, 1)'); //blue - non active
expect(await InterestsFilterButton.getText()).toEqual('Interests');
expect(await ClusterLinkText.getText()).toEqual('Clusters');
expect(await WidgetText.getText()).toEqual('Clusters > Pathways');
expect(await WidgetSubText.getText()).toEqual('To start your career exploration, select a pathway below.');
expect(await CybersecurityManagementMGT.getText()).toEqual('Cybersecurity Management (MGT)');
expect(await RiskManagementRSK.getText()).toEqual('Risk Management (RSK)');
expect(await ExecutiveCyberLeadershipEXL.getText()).toEqual('Executive Cyber Leadership (EXL)');
expect(await DisabledPreviousLinkText.getText()).toEqual('Previous');
expect(await DisabledNextLinkText.getText()).toEqual('Next');
await CybersecurityManagementMGTSelectButton.click().then(function() {
browser.sleep(2500);
});
expect(SkillsFilterButton.getCssValue('background-color')).toBe('rgba(26, 188, 156, 1)'); //journey green - active
expect(await SkillsFilterButton.getText()).toEqual('Skills');
expect(InterestsFilterButton.getCssValue('background-color')).toBe('rgba(60, 162, 223, 1)'); //blue - non active
expect(await InterestsFilterButton.getText()).toEqual('Interests');
expect(await ClusterLinkText.getText()).toEqual('Clusters');
expect(await PathwaysLinkText.getText()).toEqual('Pathways');
expect(await WidgetText.getText()).toEqual('Clusters > Pathways > Occupations');
expect(await WidgetSubText.getText()).toEqual('To start your career exploration, click the Learn More icon of an occupation below.');
expect(await CommunicationsSecurityCOMSECManager.getText()).toEqual('Communications Security (COMSEC) Manager');
expect(await CommunicationsSecurityCOMSECManagerLearnMoreIcon.getText()).toEqual('Learn More');
expect(await CommunicationsSecurityCOMSECManagerMapIcon.getText()).toEqual('Map');
expect(await CommunicationsSecurityCOMSECManagerJourneymanIcon.getText()).toEqual('Journey');
expect(await CommunicationsSecurityCOMSECManagerVideoIcon.getText()).toEqual('Video');
expect(await DisabledPreviousLinkText.getText()).toEqual('Previous');
expect(await DisabledNextLinkText.getText()).toEqual('Next');
browser.waitForAngular();
browser.getCurrentUrl();
});
}
function InterestSurveyResultsCreateJourney() {
it(': InterestSurveyResultsCreateJourney, should create a Journey to Top Interest Survey Result', async function () {
var CommunicationsSecurityCOMSECManagerJourneymanIcon = element(by.css('.territoryCardActionBarText:nth-child(3)'));
var JourneySideBarHeaderOne = element(by.css('.side-bar-child-text > span'));
var JourneyInfoIcon = element(by.css('span > .journey-info-circle'));
var JourneyInfoDIVTitle = element(by.css('.col-lg-12 > .ng-binding'));
var JourneyInfoDIVSubText = element(by.css('.col-lg-12:nth-child(3)'));
var JourneyInfoDIVXCloseIcon = element(by.css('.fa-times'));
var JourneyEntryPoint = element(by.css('.journeyInput'));
var SelectEntryPointDropDown = element(by.css('.ng-scope:nth-child(5) > .sidebarScrollListTxt > .ng-binding'));
var StartYourJourneyButton = element(by.css('.journeyStartBtnEnable'));
var JourneysActionTitleHeader = element(by.css('div:nth-child(2) > .ng-binding'));
var JourneyResultTitle = element(by.css('#journeyitem0 .side-bar-child-text'));
var JourneyDetailIcon = element(by.css('#tab-content-0 .journey-info-circle'));
var JourneyEntryPointCluster = element(by.css('#journeyViewToolTip_0 .ng-binding:nth-child(1)'));
var JourneyEntryPointPathway = element(by.css('#journeyViewToolTip_0 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var JourneyEntryPointOccupation = element(by.css('#journeyViewToolTip_0 .side-bar-journey-detail-child-txt:nth-child(5)'));
var JourneyCollegeStop = element(by.css('#journeyViewToolTip_1 .side-bar-journey-detail-child-txt:nth-child(5)'));
var JourneyExitPointCluster = element(by.css('#journeyViewToolTip_2 .ng-binding:nth-child(1)'));
var JourneyExitPointPathway = element(by.css('#journeyViewToolTip_2 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var JourneyExitPointOccupation = element(by.css('#journeyViewToolTip_2 .side-bar-journey-detail-child-txt:nth-child(5)'));
var JourneySaveIcon = element(by.css('div:nth-child(3) > div > .mapActionBarActive > .fas'));
var JourneyStopDIVTitle = element(by.css('.row:nth-child(1) > .col-md-12:nth-child(1)'));
var JourneyStopDIVTitleCardOne = element(by.css('.item:nth-child(4) > .ng-scope:nth-child(1) .waypointCardTitle'));
var JourneyStopDIVTitleCardTwo = element(by.css('.item:nth-child(4) > .ng-scope:nth-child(2) .waypointCardTitle'));
var JourneyStopDIVTitleCardThree = element(by.css('.item:nth-child(4) > .ng-scope:nth-child(3) .waypointCardTitle'));
var JourneyStopDIVSubText = element(by.css('#addWaypointsModalAddedWaypointsCarousel .ng-scope'));
var JourneyStopDIVSkipLink = element(by.css('.btn-inverse'));
var JourneySavedTitle = element(by.css('#sideBarTabJourneyItemHeader > .side-bar-child-text'));
await CommunicationsSecurityCOMSECManagerJourneymanIcon.click().then(function() {
browser.sleep(2500);
});
expect(await JourneySideBarHeaderOne.getText()).toEqual('Create Your Journey');
await JourneyInfoIcon.click().then(function() {
browser.sleep(1000);
});
expect(await JourneyInfoDIVTitle.getText()).toEqual('Create Your Journey');
expect(await JourneyInfoDIVSubText.getText()).toEqual('A Journey is your driving direction. Enter a starting location, such as your current grade, as well as the destination you are trying to reach, like an occupation. From there we will provide you with possible pathways to reach your goal.');
await JourneyInfoDIVXCloseIcon.click().then(function() {
browser.sleep(1000);
});
await JourneyEntryPoint.click();
browser.waitForAngular();
await JourneyEntryPoint.sendKeys('Electrical Engineer');
await SelectEntryPointDropDown.click();
browser.waitForAngular();
await StartYourJourneyButton.click();
browser.waitForAngular();
expect(await JourneysActionTitleHeader.getText()).toEqual('Journey Search Results');
expect(await JourneyResultTitle.getText()).toEqual('Electrical Engineering Technologists to Communications Security (COMSEC) Manager through College');
await JourneyDetailIcon.click().then(function() {
browser.sleep(5000);
});
expect(await JourneyEntryPointCluster.getText()).toEqual('STEM');
expect(await JourneyEntryPointPathway.getText()).toEqual('Engineering & Technology');
expect(await JourneyEntryPointOccupation.getText()).toEqual('Electrical Engineering Technologists');
expect(await JourneyCollegeStop.getText()).toEqual('College');
expect(await JourneyExitPointCluster.getText()).toEqual('Cyber Security');
expect(await JourneyExitPointPathway.getText()).toEqual('Cybersecurity Management (MGT)');
expect(await JourneyExitPointOccupation.getText()).toEqual('Communications Security (COMSEC) Manager');
await JourneySaveIcon.click().then(function() {
browser.sleep(5000);
});
expect(await JourneyStopDIVTitle.getText()).toEqual('Now that you have saved a journey, feel free to add any additional certification(s) to your journey by selecting from below!');
expect(await JourneyStopDIVTitleCardOne.getText()).toEqual('EC Council Certified Chief Information Security Officer');
expect(await JourneyStopDIVTitleCardTwo.getText()).toEqual('GIAC Reverse Engineering Malware');
expect(await JourneyStopDIVTitleCardThree.getText()).toEqual('Systems Security Certified Practitioner');
expect(await JourneyStopDIVSubText.getText()).toEqual('Your added stops will show up here.');
expect(await JourneyStopDIVSkipLink.getText()).toEqual('Skip');
await JourneyStopDIVSkipLink.click().then(function() {
browser.sleep(5000);
});
expect(await JourneySavedTitle.getText()).toEqual('Electrical Engineering Technologists to Communications Security (COMSEC) Manager through College');
expect(await JourneyEntryPointCluster.getText()).toEqual('STEM');
expect(await JourneyEntryPointPathway.getText()).toEqual('Engineering & Technology');
expect(await JourneyEntryPointOccupation.getText()).toEqual('Electrical Engineering Technologists');
expect(await JourneyCollegeStop.getText()).toEqual('College');
expect(await JourneyExitPointCluster.getText()).toEqual('Cyber Security');
expect(await JourneyExitPointPathway.getText()).toEqual('Cybersecurity Management (MGT)');
expect(await JourneyExitPointOccupation.getText()).toEqual('Communications Security (COMSEC) Manager');
expect(await JourneysActionTitleHeader.getText()).toEqual('Journey Search Results');
browser.waitForAngular();
browser.getCurrentUrl();
});
}
function DeleteCreatedJourney() {
it(': DeleteCreatedJourney, should navigate to My Journeys and delete recently created Journey', async function () {
var MyJourneysHeaderLink = element(by.css('#nbMyJourneys span'));
var MyJourneysPageTitle = element(by.css('.jrnys_lead-body-copy'));
var MyJourneysPageSubText = element(by.css('.col-md-10 .ng-scope:nth-child(1)'));
var MyJourneysSelectCreatedJourney = element(by.xpath("//span[contains(.,'Electrical Engineering Technologists to Communications Security (COMSEC) Manager through College')]"));
var NinethGradeBubble = element(by.css('#mCSB_1_container > .firstWaypoint .lblClass'));
var TenthGradeBubble = element(by.css('#mCSB_1_container > .fullSize-Journey:nth-child(2) .lblClass'));
var EleventhGradeBubble = element(by.css('#mCSB_1_container > .fullSize-Journey:nth-child(3) .lblClass'));
var MyJourneysViewOnMap = element(by.css('.col-md-4 > .btn-info'));
var MyJourneysTitleRow = element(by.css('.col-md-12 > .ng-binding'));
var MyJourneysWayPointTitleRow = element(by.css('.select-waypointTitle'));
var MyJourneysRightArrow = element(by.css('.glyphicon-menu-right'));
var MyJourneysRemoveJourneyButton = element(by.css('#saveJourneyButton'));
var MyJourneysDIVTite = element(by.css('h2'));
var MyJourneysDIVSubText = element(by.css('p:nth-child(7)'));
var MyJourneysDIVCancelButton = element(by.css('.cancel'));
var MyJourneysDIVOKButton = element(by.css('.confirm'));
var MyJourneysViewOnMap = element(by.css('.col-md-4 > .btn-info'));
var MyJourneysHowAmIDoingButton = element(by.css('.btn-success'));
var MyJourneysSubText = element(by.css('.details-resourceRowTitle'));
var MySavedJourneysTitleOne = element(by.xpath("//span[contains(.,'11 to Fitness and Wellness Coordinators through M.U.R.P.')]"));
var MySavedJourneysTitleTwo = element(by.xpath("//span[contains(.,'8 to Airfield Operations Specialists through College')]"));
var MySavedJourneysTitleThree = element(by.xpath("//span[contains(.,'10 to Computer and Information Systems Managers through Computer Security Graduate Certificate')]"));
var MySavedJourneysTitleFour = element(by.xpath("//span[contains(.,'2 to Natural Sciences Managers through Geology M.A.T./M.S.T.')]"));
await MyJourneysHeaderLink.click().then(function() {
browser.sleep(2500);
});
expect(await MyJourneysPageTitle.getText()).toEqual('My Saved Journeys');
expect(await MyJourneysPageSubText.getText()).toEqual('Select a Journey to show it on the map');
expect(await MyJourneysSelectCreatedJourney.getText()).toEqual('Electrical Engineering Technologists to Communications Security (COMSEC) Manager through College');
expect(await NinethGradeBubble.getText()).toEqual('Electrical');
expect(await TenthGradeBubble.getText()).toEqual('College');
expect(await EleventhGradeBubble.getText()).toEqual('Communication');
await MyJourneysSelectCreatedJourney.click().then(function() {
browser.sleep(2500);
});
expect(await MyJourneysTitleRow.getText()).toEqual('Electrical Engineering Technologists to Communications Security (COMSEC) Manager through College');
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('Electrical Engineering Technologists');
await MyJourneysRightArrow.click().then(function() {
browser.sleep(1500);
});
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('College');
await MyJourneysRightArrow.click().then(function() {
browser.sleep(1500);
});
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('Communications Security (COMSEC) Manager');
expect(await MyJourneysRemoveJourneyButton.getText()).toEqual('Remove Journey');
expect(await MyJourneysViewOnMap.getText()).toEqual('View On Map');
expect(await MyJourneysHowAmIDoingButton.getText()).toEqual('How am I doing?');
expect(await MyJourneysSubText.getText()).toEqual('Try these resources');
await MyJourneysRemoveJourneyButton.click().then(function() {
browser.sleep(2500);
});
expect(await MyJourneysDIVTite.getText()).toEqual('Are you sure?');
expect(await MyJourneysDIVSubText.getText()).toEqual('You will not be able to recover this journey!');
expect(await MyJourneysDIVCancelButton.getText()).toEqual('Cancel');
expect(await MyJourneysDIVOKButton.getText()).toEqual('Yes, delete it!');
await MyJourneysDIVOKButton.click().then(function() {
browser.sleep(2500);
});
expect(await MyJourneysDIVTite.getText()).toEqual('Deleted!');
expect(await MyJourneysDIVSubText.getText()).toEqual('Your journey has been deleted.');
await MyJourneysDIVOKButton.click().then(function() {
browser.sleep(2500);
});
await MyJourneysHeaderLink.click().then(function() {
browser.sleep(2500);
});
expect(await MySavedJourneysTitleOne.getText()).toEqual('11 to Fitness and Wellness Coordinators through M.U.R.P.');
expect(await MySavedJourneysTitleTwo.getText()).toEqual('8 to Airfield Operations Specialists through College');
expect(await MySavedJourneysTitleThree.getText()).toEqual('10 to Computer and Information Systems Managers through Computer Security Graduate Certificate');
expect(await MySavedJourneysTitleFour.getText()).toEqual('2 to Natural Sciences Managers through Geology M.A.T./M.S.T.');
browser.waitForAngular();
browser.getCurrentUrl();
});
}
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();
browser.sleep(1000);
await ProfileImage.click();
browser.sleep(1000);
browser.waitForAngular();
browser.getCurrentUrl();
await SignOutButton.click().then(function() {
browser.sleep(2500);
});
});
}