Updated createJourney interestSurveyResultsWidget

This commit is contained in:
2020-08-20 11:54:21 -07:00
parent defd15b1bc
commit fdc62fbbbd
5 changed files with 322 additions and 104 deletions

View File

@@ -47,6 +47,7 @@ describe('Create Journey Script', function () {
//<<<<DASHBOARD>>>> //<<<<DASHBOARD>>>>
CreateJourney(); CreateJourney();
DeleteCreatedJourney();
//Sign Out //Sign Out
SignOut(); SignOut();
@@ -263,8 +264,8 @@ function CreateJourney() {
var TenthGradeWayPointCluster = element(by.css('#journeyViewToolTip_4 .side-bar-journey-detail-child-txt:nth-child(5)')); var TenthGradeWayPointCluster = element(by.css('#journeyViewToolTip_4 .side-bar-journey-detail-child-txt:nth-child(5)'));
var EleventhGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_5 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt')); var EleventhGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_5 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var EleventhGradeWayPointCluster = element(by.css('#journeyViewToolTip_5 .side-bar-journey-detail-child-txt:nth-child(5)')); var EleventhGradeWayPointCluster = element(by.css('#journeyViewToolTip_5 .side-bar-journey-detail-child-txt:nth-child(5)'));
var TwelvethGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_6 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt')); var TwelfthGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_6 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var TwelvethGradeWayPointCluster = element(by.css('#journeyViewToolTip_6 .side-bar-journey-detail-child-txt:nth-child(5)')); var TwelfthGradeWayPointCluster = element(by.css('#journeyViewToolTip_6 .side-bar-journey-detail-child-txt:nth-child(5)'));
var CollegeStopWayPointTopLevel = element(by.css('#journeyViewToolTip_7 .ng-binding:nth-child(1)')); var CollegeStopWayPointTopLevel = element(by.css('#journeyViewToolTip_7 .ng-binding:nth-child(1)'));
var CollegeStopWayPointCluster = element(by.css('#journeyViewToolTip_7 > .ng-isolate-scope .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt')); var CollegeStopWayPointCluster = element(by.css('#journeyViewToolTip_7 > .ng-isolate-scope .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var CollegeStopWayPointPathway = element(by.css('#journeyViewToolTip_7 .side-bar-journey-detail-child-txt:nth-child(5)')); var CollegeStopWayPointPathway = element(by.css('#journeyViewToolTip_7 .side-bar-journey-detail-child-txt:nth-child(5)'));
@@ -316,27 +317,6 @@ function CreateJourney() {
var ThirdResultViewOnMapIconIcon = element(by.css('#searchitem2 div:nth-child(6) > .fas')); var ThirdResultViewOnMapIconIcon = element(by.css('#searchitem2 div:nth-child(6) > .fas'));
var ThirdResultAddIcon = element(by.css('#searchitem2 div:nth-child(5) > #mapActionBarJourneyIcon')); var ThirdResultAddIcon = element(by.css('#searchitem2 div:nth-child(5) > #mapActionBarJourneyIcon'));
var MapZoomOutIcon = element(by.css('.glyphicon-minus')); var MapZoomOutIcon = element(by.css('.glyphicon-minus'));
//Delete Created Journey
var MyJourneysHeaderLink = element(by.css('#nbMyJourneys .span-navbar-hover'));
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(.,"6 to Administrative Services Managers through Business Administration B.A./B.S.")]'));
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.css('#ee7b663d-2f15-43cc-867c-556c7fc493a5 .cursorPointer'));
var MySavedJourneysTitleTwo = element(by.css('#\\30 ac99d25-0cc4-4d8e-b8e4-785f8129d85e .cursorPointer'));
var MySavedJourneysTitleThree = element(by.css('#e0049880-9613-4fd5-9ed2-eb468cdc2e55 .cursorPointer'));
var MySavedJourneysTitleFour = element(by.css('#\\30 9731631-9cb7-449b-8a51-58d7e730e31b .cursorPointer'));
browser.executeScript('window.scrollTo(0, 1250);').then(function() { browser.executeScript('window.scrollTo(0, 1250);').then(function() {
browser.sleep(5000); browser.sleep(5000);
@@ -494,8 +474,8 @@ function CreateJourney() {
expect(await TenthGradeWayPointCluster.getText()).toEqual('10'); expect(await TenthGradeWayPointCluster.getText()).toEqual('10');
expect(await EleventhGradeWayPointTopLevel.getText()).toEqual('HS'); expect(await EleventhGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await EleventhGradeWayPointCluster.getText()).toEqual('11'); expect(await EleventhGradeWayPointCluster.getText()).toEqual('11');
expect(await TwelvethGradeWayPointTopLevel.getText()).toEqual('HS'); expect(await TwelfthGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await TwelvethGradeWayPointCluster.getText()).toEqual('12'); expect(await TwelfthGradeWayPointCluster.getText()).toEqual('12');
expect(await CollegeStopWayPointTopLevel.getText()).toEqual('College'); expect(await CollegeStopWayPointTopLevel.getText()).toEqual('College');
browser.actions().mouseMove(AddedStopWayPointPathwayFour).perform().then(function() { browser.actions().mouseMove(AddedStopWayPointPathwayFour).perform().then(function() {
browser.sleep(2500); browser.sleep(2500);
@@ -934,8 +914,8 @@ function CreateJourney() {
expect(await TenthGradeWayPointCluster.getText()).toEqual('10'); expect(await TenthGradeWayPointCluster.getText()).toEqual('10');
expect(await EleventhGradeWayPointTopLevel.getText()).toEqual('HS'); expect(await EleventhGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await EleventhGradeWayPointCluster.getText()).toEqual('11'); expect(await EleventhGradeWayPointCluster.getText()).toEqual('11');
expect(await TwelvethGradeWayPointTopLevel.getText()).toEqual('HS'); expect(await TwelfthGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await TwelvethGradeWayPointCluster.getText()).toEqual('12'); expect(await TwelfthGradeWayPointCluster.getText()).toEqual('12');
expect(await CollegeStopWayPointTopLevel.getText()).toEqual('College'); expect(await CollegeStopWayPointTopLevel.getText()).toEqual('College');
browser.actions().mouseMove(JourneyNewEndWayPointPathway).perform().then(function() { browser.actions().mouseMove(JourneyNewEndWayPointPathway).perform().then(function() {
browser.sleep(2500); browser.sleep(2500);
@@ -957,7 +937,69 @@ function CreateJourney() {
expect(await JourneyNewEndWayPointTopLevel.getText()).toEqual('Administration'); expect(await JourneyNewEndWayPointTopLevel.getText()).toEqual('Administration');
expect(await JourneyNewEndWayPointCluster.getText()).toEqual('Management'); expect(await JourneyNewEndWayPointCluster.getText()).toEqual('Management');
expect(await JourneyNewEndWayPointPathway.getText()).toEqual('Administrative Services Managers'); expect(await JourneyNewEndWayPointPathway.getText()).toEqual('Administrative Services Managers');
//Delete Created Journey 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-navbar-hover'));
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(.,"6 to Administrative Services Managers through Business Administration B.A./B.S.")]'));
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 JourneysActionTitleHeader = element(by.css('div:nth-child(2) > .ng-binding'));
var ActionTitleBar = element(by.css('#journey-view-single > .side-bar-child-text'));
var EditJourneyLink = element(by.linkText('Edit Journey'));
var JourneyEntryWayPointTopLevel = element(by.css('#journeyViewToolTip_0 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var JourneyEntryWayPointCluster = element(by.css('#journeyViewToolTip_0 .side-bar-journey-detail-child-txt:nth-child(5)'));
var SeventhGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_1 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var SeventhGradeWayPointCluster = element(by.css('#journeyViewToolTip_1 .side-bar-journey-detail-child-txt:nth-child(5)'));
var EightGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_2 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var EightGradeWayPointCluster = element(by.css('#journeyViewToolTip_2 .side-bar-journey-detail-child-txt:nth-child(5)'));
var NinethGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_3 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var NinethGradeWayPointCluster = element(by.css('#journeyViewToolTip_3 .side-bar-journey-detail-child-txt:nth-child(5)'));
var TenthGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_4 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var TenthGradeWayPointCluster = element(by.css('#journeyViewToolTip_4 .side-bar-journey-detail-child-txt:nth-child(5)'));
var EleventhGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_5 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var EleventhGradeWayPointCluster = element(by.css('#journeyViewToolTip_5 .side-bar-journey-detail-child-txt:nth-child(5)'));
var TwelfthGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_6 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var TwelfthGradeWayPointCluster = element(by.css('#journeyViewToolTip_6 .side-bar-journey-detail-child-txt:nth-child(5)'));
var CollegeStopWayPointTopLevel = element(by.css('#journeyViewToolTip_7 .ng-binding:nth-child(1)'));
var CollegeStopWayPointCluster = element(by.css('#journeyViewToolTip_7 > .ng-isolate-scope .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var CollegeStopWayPointPathway = element(by.css('#journeyViewToolTip_7 .side-bar-journey-detail-child-txt:nth-child(5)'));
var AddedStopWayPointTopLevelOne = element(by.css('#journeyViewToolTip_8 .ng-binding:nth-child(1)'));
var AddedStopWayPointClusterOne = element(by.css('#journeyViewToolTip_8 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var AddedStopWayPointPathwayOne = element(by.css('#journeyViewToolTip_8 .side-bar-journey-detail-child-txt:nth-child(5)'));
var AddedStopWayPointTopLevelTwo = element(by.css('#journeyViewToolTip_9 .ng-binding:nth-child(1)'));
var AddedStopWayPointClusterTwo = element(by.css('#journeyViewToolTip_9 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var AddedStopWayPointPathwayTwo = element(by.css('#journeyViewToolTip_9 .side-bar-journey-detail-child-txt:nth-child(5)'));
var AddedStopWayPointTopLevelThree = element(by.css('#journeyViewToolTip_10 .ng-binding:nth-child(1)'));
var AddedStopWayPointClusterThree = element(by.css('#journeyViewToolTip_10 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var AddedStopWayPointPathwayThree = element(by.css('#journeyViewToolTip_10 .side-bar-journey-detail-child-txt:nth-child(5)'));
var AddedStopWayPointTopLevelFour = element(by.css('#journeyViewToolTip_11 .ng-binding:nth-child(1)'));
var AddedStopWayPointClusterFour = element(by.css('#journeyViewToolTip_11 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var AddedStopWayPointPathwayFour = element(by.css('#journeyViewToolTip_11 .side-bar-journey-detail-child-txt:nth-child(5)'));
var JourneyNewEndWayPointTopLevel = element(by.css('#journeyViewToolTip_12 .ng-binding:nth-child(1)'));
var JourneyNewEndWayPointCluster = element(by.css('#journeyViewToolTip_12 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var JourneyNewEndWayPointPathway = element(by.css('#journeyViewToolTip_12 .side-bar-journey-detail-child-txt:nth-child(5)'));
var MyJourneysHowAmIDoingButton = element(by.css('.btn-success'));
var MyJourneysSubText = element(by.css('.details-resourceRowTitle'));
var MySavedJourneysTitleOne = element(by.css('#ee7b663d-2f15-43cc-867c-556c7fc493a5 .cursorPointer'));
var MySavedJourneysTitleTwo = element(by.css('#\\30 ac99d25-0cc4-4d8e-b8e4-785f8129d85e .cursorPointer'));
var MySavedJourneysTitleThree = element(by.css('#e0049880-9613-4fd5-9ed2-eb468cdc2e55 .cursorPointer'));
var MySavedJourneysTitleFour = element(by.css('#\\30 9731631-9cb7-449b-8a51-58d7e730e31b .cursorPointer'));
await MyJourneysHeaderLink.click().then(function() { await MyJourneysHeaderLink.click().then(function() {
browser.sleep(2500); browser.sleep(2500);
}); });
@@ -1027,7 +1069,44 @@ function CreateJourney() {
await MyJourneysViewOnMap.click().then(function() { await MyJourneysViewOnMap.click().then(function() {
browser.sleep(5000); browser.sleep(5000);
}); });
//add map checks expect(await JourneysActionTitleHeader.getText()).toEqual('Journey View');
expect(await ActionTitleBar.getText()).toEqual('6 to Administrative Services Managers through Business Administration B.A./B.S.');
expect(await EditJourneyLink.getText()).toEqual('Edit Journey');
expect(await JourneyEntryWayPointTopLevel.getText()).toEqual('K-8');
expect(await JourneyEntryWayPointCluster.getText()).toEqual('6');
expect(await SeventhGradeWayPointTopLevel.getText()).toEqual('K-8');
expect(await SeventhGradeWayPointCluster.getText()).toEqual('7');
expect(await EightGradeWayPointTopLevel.getText()).toEqual('K-8');
expect(await EightGradeWayPointCluster.getText()).toEqual('8');
expect(await NinethGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await NinethGradeWayPointCluster.getText()).toEqual('9');
expect(await TenthGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await TenthGradeWayPointCluster.getText()).toEqual('10');
expect(await EleventhGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await EleventhGradeWayPointCluster.getText()).toEqual('11');
expect(await TwelfthGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await TwelfthGradeWayPointCluster.getText()).toEqual('12');
expect(await CollegeStopWayPointTopLevel.getText()).toEqual('College');
browser.actions().mouseMove(JourneyNewEndWayPointPathway).perform().then(function() {
browser.sleep(2500);
});
expect(await CollegeStopWayPointCluster.getText()).toEqual('Administration');
expect(await CollegeStopWayPointPathway.getText()).toEqual('Master of Business Administration (MBA)');
expect(await AddedStopWayPointTopLevelOne.getText()).toContain('Core');
expect(await AddedStopWayPointClusterOne.getText()).toEqual('Other Certifications');
expect(await AddedStopWayPointPathwayOne.getText()).toEqual('Certified Practice Manager');
expect(await AddedStopWayPointTopLevelTwo.getText()).toEqual('Advanced');
expect(await AddedStopWayPointClusterTwo.getText()).toEqual('Other Certifications');
expect(await AddedStopWayPointPathwayTwo.getText()).toEqual('Certified Legal Manager');
expect(await AddedStopWayPointTopLevelThree.getText()).toEqual('IT');
expect(await AddedStopWayPointClusterThree.getText()).toEqual('Programming & Software Development');
expect(await AddedStopWayPointPathwayThree.getText()).toEqual('Architectural and Engineering Managers');
expect(await AddedStopWayPointTopLevelFour.getText()).toEqual('College');
expect(await AddedStopWayPointClusterFour.getText()).toEqual('Administration');
expect(await AddedStopWayPointPathwayFour.getText()).toEqual('Business Administration B.A./B.S.');
expect(await JourneyNewEndWayPointTopLevel.getText()).toEqual('Administration');
expect(await JourneyNewEndWayPointCluster.getText()).toEqual('Management');
expect(await JourneyNewEndWayPointPathway.getText()).toEqual('Administrative Services Managers');
await MyJourneysHeaderLink.click().then(function() { await MyJourneysHeaderLink.click().then(function() {
browser.sleep(2500); browser.sleep(2500);
}); });

View File

@@ -47,8 +47,8 @@ describe('Interest Survey Results Widget Script', function () {
InterestSurveyResultsWidgetRetake(); InterestSurveyResultsWidgetRetake();
InterestSurveyResultsWidgetEdit(); InterestSurveyResultsWidgetEdit();
InterestSurveyResultsWidgetResults(); InterestSurveyResultsWidgetResults();
InterestSurveyResultsCreateJourney(); InterestSurveyResultsCreateJourney();
DeleteCreatedJourney();
//Sign Out*/ //Sign Out*/
SignOut(); SignOut();
@@ -162,7 +162,7 @@ function InterestSurveyResultsWidgetEdit() {
it(': InterestSurveyResultsWidgetEdit, should interact with Interest Survey Results widget, validate results', async function () { it(': InterestSurveyResultsWidgetEdit, should interact with Interest Survey Results widget, validate results', async function () {
var InterestSurveyWidgetTitle = element(by.css('.fullHeight:nth-child(2) > div:nth-child(2) > .jrnys_lead-body-copy > div')); var InterestSurveyWidgetTitle = element(by.css('.fullHeight:nth-child(2) > div:nth-child(2) > .jrnys_lead-body-copy > div'));
var InterestEditLink = element(by.css('.fa-pencil:nth-child(1)')); var InterestEditLink = element(by.css('.fa-pencil:nth-child(1)'));
var EditInterestDivTitle = element(by.css('#interests .jrnys_lead-body-copy')); var EditInterestDIVTitle = element(by.css('#interests .jrnys_lead-body-copy'));
var EditRealisticTitle = element(by.css('.ng-scope:nth-child(1) > .row-padding-mobile .jrnys_support-tex > .ng-binding')); var EditRealisticTitle = element(by.css('.ng-scope:nth-child(1) > .row-padding-mobile .jrnys_support-tex > .ng-binding'));
var EditRealisticTextBox = element(by.id('Realistic')); var EditRealisticTextBox = element(by.id('Realistic'));
var EditRealisticDescription = element(by.css('.ng-scope:nth-child(1) > .row-padding-mobile .color3a-color')); var EditRealisticDescription = element(by.css('.ng-scope:nth-child(1) > .row-padding-mobile .color3a-color'));
@@ -181,7 +181,7 @@ function InterestSurveyResultsWidgetEdit() {
var EditConventionalTitle = element(by.css('.ng-scope:nth-child(6) .jrnys_support-tex > .ng-binding')); var EditConventionalTitle = element(by.css('.ng-scope:nth-child(6) .jrnys_support-tex > .ng-binding'));
var EditConventionalTextBox = element(by.id('Conventional')); var EditConventionalTextBox = element(by.id('Conventional'));
var EditConventionalDescription = element(by.css('.ng-scope:nth-child(6) .color3a-color')); var EditConventionalDescription = element(by.css('.ng-scope:nth-child(6) .color3a-color'));
var EditInterestSurveyDivSaveButton = element(by.css('.btn-info:nth-child(2)')); var EditInterestSurveyDIVSaveButton = element(by.css('.btn-info:nth-child(2)'));
var TopResultTitleOne = element(by.css('.surveyResultSpacingTop > div > div > .ng-binding')); var TopResultTitleOne = element(by.css('.surveyResultSpacingTop > div > div > .ng-binding'));
var TopResultDescriptionOne = element(by.css('.surveyResultSpacingTop .surveyResultTruncateText')); var TopResultDescriptionOne = element(by.css('.surveyResultSpacingTop .surveyResultTruncateText'));
var TopResultsReadMoreLinkOne = element(by.css('.surveyResultSpacingTop > div > div:nth-child(2)')); var TopResultsReadMoreLinkOne = element(by.css('.surveyResultSpacingTop > div > div:nth-child(2)'));
@@ -192,7 +192,7 @@ function InterestSurveyResultsWidgetEdit() {
var AdministrativeLawJudgesAdjudicatorsAndHearingOfficers = element(by.css('#\\39 d53706e-b04f-4fcb-a36e-d9c48934c2e1 > #territoryCardContainer .territoryCardTitleText > .ng-binding')); var AdministrativeLawJudgesAdjudicatorsAndHearingOfficers = element(by.css('#\\39 d53706e-b04f-4fcb-a36e-d9c48934c2e1 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var AdministrativeLawJudgesAdjudicatorsAndHearingOfficersAtAGlanceIcon = element(by.css('#\\39 d53706e-b04f-4fcb-a36e-d9c48934c2e1 > #territoryCardContainer > div > div > div .territoryCardItemText')); var AdministrativeLawJudgesAdjudicatorsAndHearingOfficersAtAGlanceIcon = element(by.css('#\\39 d53706e-b04f-4fcb-a36e-d9c48934c2e1 > #territoryCardContainer > div > div > div .territoryCardItemText'));
var AdministrativeLawJudgesAdjudicatorsAndHearingOfficersAtBestFitIcon = element(by.css('#\\39 d53706e-b04f-4fcb-a36e-d9c48934c2e1 > #territoryCardContainer .ng-scope > div > div:nth-child(1) > .territoryCardItemText')); var AdministrativeLawJudgesAdjudicatorsAndHearingOfficersAtBestFitIcon = element(by.css('#\\39 d53706e-b04f-4fcb-a36e-d9c48934c2e1 > #territoryCardContainer .ng-scope > div > div:nth-child(1) > .territoryCardItemText'));
var AdministrativeServicesManagers = element(by.css('#aa3ce6df-8851-4f10-8341-a4b7cdac7b7d > #territoryCardContainer .territoryCardTitleText > .ng-binding')); var AdministrativeServicesManagers = element(by.css('#d64b79d0-cadf-4b66-afc1-ae35273f3a78 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var AirTrafficControllers = element(by.css('#\\30 2c1f459-be14-4ea7-8229-404af8ccb881 > #territoryCardContainer .territoryCardTitleText > .ng-binding')); var AirTrafficControllers = element(by.css('#\\30 2c1f459-be14-4ea7-8229-404af8ccb881 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
var TopResultTitleTwo = element(by.css('.surveyResultSpacing:nth-child(4) > div > div > .ng-binding')); var TopResultTitleTwo = element(by.css('.surveyResultSpacing:nth-child(4) > div > div > .ng-binding'));
var TopResultDescriptionTwo = element(by.css('.ng-scope:nth-child(4) .surveyResultTruncateText')); var TopResultDescriptionTwo = element(by.css('.ng-scope:nth-child(4) .surveyResultTruncateText'));
@@ -200,39 +200,30 @@ function InterestSurveyResultsWidgetEdit() {
var TopResultTitleThree = element(by.css('.surveyResultSpacing:nth-child(5) > div > div > .ng-binding')); var TopResultTitleThree = element(by.css('.surveyResultSpacing:nth-child(5) > div > div > .ng-binding'));
var TopResultDescriptionThree = element(by.css('.ng-scope:nth-child(5) .surveyResultTruncateText')); var TopResultDescriptionThree = element(by.css('.ng-scope:nth-child(5) .surveyResultTruncateText'));
var TopResultsReadMoreLinkThree = element(by.css('.surveyResultSpacing:nth-child(5) > div > div:nth-child(2)')); var TopResultsReadMoreLinkThree = element(by.css('.surveyResultSpacing:nth-child(5) > div > div:nth-child(2)'));
var InterestResultsLink = element(by.css('div:nth-child(6) .fa-chart-bar')); var InterestResultsLink = element(by.css('div:nth-child(6) .fa-chart-bar'));
var PageTitle = element(by.css('.surveyContainer > .col-xs-offset-1')); var PageTitle = element(by.css('.surveyContainer > .col-xs-offset-1'));
var TopThreeTraitsHeader = element(by.css('.fullHeight > .jrnys_lead-body-copy')); var TopThreeTraitsHeader = element(by.css('.fullHeight > .jrnys_lead-body-copy'));
var TopThreeTraitsOne = element(by.css('.col-md-4:nth-child(1) .jrnys_lead-body-copy')); var TopTraitsTitleOne = element(by.css('.ng-scope:nth-child(2) > .row > .col-sm-6:nth-child(1) > .jrnys_lead-body-copy'));
var TopThreeTraitsDescriptionOne = element(by.css('.col-md-4:nth-child(1) .ng-binding:nth-child(2)')); var TopTraitsDescriptionOne = element(by.css('.ng-scope:nth-child(2) > .row > .col-sm-6:nth-child(1) > .ng-binding:nth-child(2)'));
var TopThreeTraitsTwo = element(by.css('.col-md-4:nth-child(2) .jrnys_lead-body-copy')); var TopTraitsTitleTwo = element(by.css('.ng-scope:nth-child(2) > .row > .col-sm-6:nth-child(2) > .jrnys_lead-body-copy'));
var TopThreeTraitsDescriptionTwo = element(by.css('.col-md-4:nth-child(2) .ng-binding:nth-child(2)')); var TopTraitsDescriptionTwo = element(by.css('.ng-scope:nth-child(2) > .row > .col-sm-6:nth-child(2) > .ng-binding:nth-child(2)'));
var TopThreeTraitsThree = element(by.css('.col-md-4:nth-child(3) .jrnys_lead-body-copy')); var TopTraitsTitleThree = element(by.css('.ng-scope:nth-child(3) > .row > .col-sm-6:nth-child(1) > .jrnys_lead-body-copy'));
var TopThreeTraitsDescriptionThree = element(by.css('.col-md-4:nth-child(3) .ng-binding:nth-child(2)')); var TopTraitsDescriptionThree = element(by.css('.ng-scope:nth-child(3) > .row > .col-sm-6:nth-child(1) > .ng-binding:nth-child(2)'));
var ViewAllLink = element(by.linkText('View All')); var TopTraitsTitleFour = element(by.css('.ng-scope:nth-child(3) > .row > .col-sm-6:nth-child(2) > .jrnys_lead-body-copy'));
var TopTraitsOne = element(by.css('.row:nth-child(1) > .col-md-6:nth-child(1) > .jrnys_lead-body-copy')); var TopTraitsDescriptionFour = element(by.css('.ng-scope:nth-child(3) > .row > .col-sm-6:nth-child(2) > .ng-binding:nth-child(2)'));
var TopTraitsOneDescription = element(by.css('.row:nth-child(1) > .col-md-6:nth-child(1) > .ng-binding:nth-child(2)')); var TopTraitsTitleFive = element(by.css('.ng-scope:nth-child(4) .col-sm-6:nth-child(1) > .jrnys_lead-body-copy'));
var TopTraitsTwo = element(by.css('.row:nth-child(1) > .col-md-6:nth-child(2) > .jrnys_lead-body-copy')); var TopTraitsDescriptionFive = element(by.css('.ng-scope:nth-child(4) .col-sm-6:nth-child(1) > .ng-binding:nth-child(2)'));
var TopTraitsTwoDescription = element(by.css('.row:nth-child(1) > .col-md-6:nth-child(2) > .ng-binding:nth-child(2)')); var TopTraitsTitleSix = element(by.css('.ng-scope:nth-child(4) .col-sm-6:nth-child(2) > .jrnys_lead-body-copy'));
var TopTraitsThree = element(by.css('.row:nth-child(2) > .col-md-6:nth-child(1) > .jrnys_lead-body-copy')); var TopTraitsDescriptionSix = element(by.css('.ng-scope:nth-child(4) .col-sm-6:nth-child(2) > .ng-binding:nth-child(2)'));
var TopTraitsThreeDescription = element(by.css('.row:nth-child(2) > .col-md-6:nth-child(1) > .ng-binding:nth-child(2)'));
var TopTraitsFour = element(by.css('.row:nth-child(2) > .col-md-6:nth-child(2) > .jrnys_lead-body-copy'));
var TopTraitsFourDescription = element(by.css('.row:nth-child(2) > .col-md-6:nth-child(2) > .ng-binding:nth-child(2)'));
var TopTraitsFive = element(by.css('.row:nth-child(3) > .col-md-6:nth-child(1) > .jrnys_lead-body-copy'));
var TopTraitsFiveDescription = element(by.css('.row:nth-child(3) > .col-md-6:nth-child(1) > .ng-binding:nth-child(2)'));
var TopTraitsSix = element(by.css('.row:nth-child(3) > .col-md-6:nth-child(2) > .jrnys_lead-body-copy'));
var TopTraitsSixDescription = element(by.css('.row:nth-child(3) > .col-md-6:nth-child(2) > .ng-binding:nth-child(2)'));
var XCloseIcon = element(by.css('.close'));
var ShareResultsIcon = element(by.css('.fa-share-alt')); var ShareResultsIcon = element(by.css('.fa-share-alt'));
var ShareResultsDivTitle = element(by.css('#interestSurveyShareResult > .jrnys_lead-body-copy')); var ShareResultsDIVTitle = element(by.css('#interestSurveyShareResult > .jrnys_lead-body-copy'));
var ToTextBox = element(by.css('tr:nth-child(2) .form-control')); var ToTextBox = element(by.css('tr:nth-child(2) .form-control'));
var FromTextBox = element(by.css('tr:nth-child(1) .form-control')); var FromTextBox = element(by.css('tr:nth-child(1) .form-control'));
var CancelButton = element(by.css('.btn-alt-info')); var CancelButton = element(by.css('.btn-alt-info'));
var SendButton = element(by.css('tr:nth-child(7) .btn-info')); var SendButton = element(by.css('tr:nth-child(7) .btn-info'));
var DivAlertTitle = element(by.css('h2')); var DIVAlertTitle = element(by.css('h2'));
var DivAlertMessage = element(by.css('p:nth-child(7)')); var DIVAlertMessage = element(by.css('p:nth-child(7)'));
var DivOKButton = element(by.css('.confirm')); var DIVOKButton = element(by.css('.confirm'));
var EC = protractor.ExpectedConditions; var EC = protractor.ExpectedConditions;
//Scroll down to Interest Survey Results widget //Scroll down to Interest Survey Results widget
@@ -242,7 +233,7 @@ function InterestSurveyResultsWidgetEdit() {
await InterestEditLink.click().then(function() { await InterestEditLink.click().then(function() {
browser.sleep(2500); browser.sleep(2500);
}); });
expect(await EditInterestDivTitle.getText()).toEqual('Interests'); expect(await EditInterestDIVTitle.getText()).toEqual('Interests');
expect(await EditRealisticTitle.getText()).toEqual('Realistic'); expect(await EditRealisticTitle.getText()).toEqual('Realistic');
await EditRealisticTextBox.clear(); await EditRealisticTextBox.clear();
await EditRealisticTextBox.sendKeys('21'); await EditRealisticTextBox.sendKeys('21');
@@ -275,7 +266,7 @@ function InterestSurveyResultsWidgetEdit() {
browser.sleep(1000); browser.sleep(1000);
expect(await EditConventionalDescription.getText()).toEqual('People might call you TYPE A, but they’re just jealous of your ability to get things done.'); expect(await EditConventionalDescription.getText()).toEqual('People might call you TYPE A, but they’re just jealous of your ability to get things done.');
browser.sleep(1000); browser.sleep(1000);
await EditInterestSurveyDivSaveButton.click(); await EditInterestSurveyDIVSaveButton.click();
browser.sleep(1000); browser.sleep(1000);
expect(await InterestSurveyWidgetTitle.getText()).toEqual('Interest Survey Results'); expect(await InterestSurveyWidgetTitle.getText()).toEqual('Interest Survey Results');
expect(await TopResultTitleOne.getText()).toEqual('Enterprising (27)'); expect(await TopResultTitleOne.getText()).toEqual('Enterprising (27)');
@@ -329,46 +320,33 @@ function InterestSurveyResultsWidgetEdit() {
browser.sleep(10000); browser.sleep(10000);
}); });
expect(await PageTitle.getText()).toEqual('Interest Survey Result'); expect(await PageTitle.getText()).toEqual('Interest Survey Result');
expect(await TopThreeTraitsHeader.getText()).toEqual('Your top 3 traits View All'); expect(await TopThreeTraitsHeader.getText()).toEqual('Check out your traits!');
expect(await TopThreeTraitsOne.getText()).toEqual('Enterprising (27)'); expect(await TopTraitsTitleOne.getText()).toEqual('Enterprising (27)');
expect(await TopThreeTraitsDescriptionOne.getText()).toEqual('People who are adventurous, ambitious, assertive, extroverted, energetic, enthusiastic, confident, optimistic, dominant, persuasive, and motivational. They prefer work that involves leadership, business, politics, and public speaking. They enjoy being in charge, taking risks, debating and competing.'); expect(await TopTraitsDescriptionOne.getText()).toEqual('People who are adventurous, ambitious, assertive, extroverted, energetic, enthusiastic, confident, optimistic, dominant, persuasive, and motivational. They prefer work that involves leadership, business, politics, and public speaking. They enjoy being in charge, taking risks, debating and competing.');
expect(await TopThreeTraitsTwo.getText()).toEqual('Investigative (25)'); expect(await TopTraitsTitleTwo.getText()).toEqual('Investigative (25)');
expect(await TopThreeTraitsDescriptionTwo.getText()).toEqual('People who are intellectual, introspective, inquisitive, curious, methodical, rational, analytical, and logical. They prefer tasks that are scholarly, scientific, technical, or medical and activities that involve thought, observation, investigation, exploration, and discovery. They like to solve problems, perform experiments, and conduct research.'); expect(await TopTraitsDescriptionTwo.getText()).toEqual('People who are intellectual, introspective, inquisitive, curious, methodical, rational, analytical, and logical. They prefer tasks that are scholarly, scientific, technical, or medical and activities that involve thought, observation, investigation, exploration, and discovery. They like to solve problems, perform experiments, and conduct research.');
expect(await TopThreeTraitsThree.getText()).toEqual('Conventional (23)'); expect(await TopTraitsTitleThree.getText()).toEqual('Conventional (23)');
expect(await TopThreeTraitsDescriptionThree.getText()).toEqual('People who are conscientious and conservative, logical, efficient, orderly, organized, thorough, and detail-oriented. They are individuals who value precision and accuracy. They excel in practical tasks, quantitative measurements, structured environments and people who follow the rules. They prefer work that involves accounting, statistics, mathematics, numerical activities, and office settings.'); expect(await TopTraitsDescriptionThree.getText()).toEqual('People who are conscientious and conservative, logical, efficient, orderly, organized, thorough, and detail-oriented. They are individuals who value precision and accuracy. They excel in practical tasks, quantitative measurements, structured environments and people who follow the rules. They prefer work that involves accounting, statistics, mathematics, numerical activities, and office settings.');
await ViewAllLink.click().then(function() { expect(await TopTraitsTitleFour.getText()).toEqual('Social (22)');
browser.sleep(1000); expect(await TopTraitsDescriptionFour.getText()).toEqual('People who are kind, generous, cooperative, patient, caring, helpful, empathetic, tactful, and friendly. They prefer tasks that involve socializing, helping others, teaching, teamwork, social interaction, relationship building, humanitarian, educational, philanthropic, interpersonal, and service-oriented work.');
}); expect(await TopTraitsTitleFive.getText()).toEqual('Realistic (21)');
expect(await TopTraitsOne.getText()).toEqual('Enterprising (27)'); expect(await TopTraitsDescriptionFive.getText()).toEqual('People who are independent, stable, persistent, genuine, practical, and thrifty. They tend to be no-nonsense and down-to-earth while enjoying physical, athletic, or mechanical activity. They prefer things rather than ideas or people such as being outdoors, using tools, operating machines, interacting with animals, and working with their hands. They also value the natural, concrete, and tangible.');
expect(await TopTraitsOneDescription.getText()).toEqual('People who are adventurous, ambitious, assertive, extroverted, energetic, enthusiastic, confident, optimistic, dominant, persuasive, and motivational. They prefer work that involves leadership, business, politics, and public speaking. They enjoy being in charge, taking risks, debating and competing.'); expect(await TopTraitsTitleSix.getText()).toEqual('Artistic (17)');
expect(await TopTraitsTwo.getText()).toEqual('Investigative (25)'); expect(await TopTraitsDescriptionSix.getText()).toEqual('People who are creative, intuitive, sensitive, articulate, expressive, unstructured, original, nonconforming, and innovative who rely on feelings, imagination, inspiration and who are spontaneous and open-minded. They prefer to work with ideas, abstractions, and concepts. They also enjoy work that is literary, verbal, visual and aesthetic. They typically excel in art, music, dance, drawing, painting, sculpting, drafting, writing, drama, communicating, design, fashion.');
expect(await TopTraitsTwoDescription.getText()).toEqual('People who are intellectual, introspective, inquisitive, curious, methodical, rational, analytical, and logical. They prefer tasks that are scholarly, scientific, technical, or medical and activities that involve thought, observation, investigation, exploration, and discovery. They like to solve problems, perform experiments, and conduct research.');
expect(await TopTraitsThree.getText()).toEqual('Conventional (23)');
expect(await TopTraitsThreeDescription.getText()).toEqual('People who are conscientious and conservative, logical, efficient, orderly, organized, thorough, and detail-oriented. They are individuals who value precision and accuracy. They excel in practical tasks, quantitative measurements, structured environments and people who follow the rules. They prefer work that involves accounting, statistics, mathematics, numerical activities, and office settings.');
expect(await TopTraitsFour.getText()).toEqual('Social (22)');
expect(await TopTraitsFourDescription.getText()).toEqual('People who are kind, generous, cooperative, patient, caring, helpful, empathetic, tactful, and friendly. They prefer tasks that involve socializing, helping others, teaching, teamwork, social interaction, relationship building, humanitarian, educational, philanthropic, interpersonal, and service-oriented work.');
expect(await TopTraitsFive.getText()).toEqual('Realistic (21)');
expect(await TopTraitsFiveDescription.getText()).toEqual('People who are independent, stable, persistent, genuine, practical, and thrifty. They tend to be no-nonsense and down-to-earth while enjoying physical, athletic, or mechanical activity. They prefer things rather than ideas or people such as being outdoors, using tools, operating machines, interacting with animals, and working with their hands. They also value the natural, concrete, and tangible.');
expect(await TopTraitsSix.getText()).toEqual('Artistic (17)');
expect(await TopTraitsSixDescription.getText()).toEqual('People who are creative, intuitive, sensitive, articulate, expressive, unstructured, original, nonconforming, and innovative who rely on feelings, imagination, inspiration and who are spontaneous and open-minded. They prefer to work with ideas, abstractions, and concepts. They also enjoy work that is literary, verbal, visual and aesthetic. They typically excel in art, music, dance, drawing, painting, sculpting, drafting, writing, drama, communicating, design, fashion.');
await XCloseIcon.click().then(function() {
browser.sleep(1000);
});
browser.waitForAngular();
await ShareResultsIcon.click(); await ShareResultsIcon.click();
expect(await ShareResultsDivTitle.getText()).toEqual('Email Your Results'); expect(await ShareResultsDIVTitle.getText()).toEqual('Email Your Results');
await SendButton.click(); await SendButton.click();
browser.sleep(1000); browser.sleep(1000);
expect(await DivAlertTitle.getText()).toEqual('No Email'); expect(await DIVAlertTitle.getText()).toEqual('No Email');
expect(await DivAlertMessage.getText()).toEqual('Please provide at least one email address to send.'); expect(await DIVAlertMessage.getText()).toEqual('Please provide at least one email address to send.');
await DivOKButton.click(); await DIVOKButton.click();
browser.waitForAngular(); browser.waitForAngular();
await ToTextBox.sendKeys('jhuerta@edmin'); await ToTextBox.sendKeys('jhuerta@edmin');
await SendButton.click(); await SendButton.click();
browser.sleep(1000); browser.sleep(1000);
expect(await DivAlertTitle.getText()).toEqual('Invalid Email'); expect(await DIVAlertTitle.getText()).toEqual('Invalid Email');
expect(await DivAlertMessage.getText()).toEqual('jhuerta@edmin is not a valid email address.'); expect(await DIVAlertMessage.getText()).toEqual('jhuerta@edmin is not a valid email address.');
await DivOKButton.click(); await DIVOKButton.click();
browser.sleep(1000); browser.sleep(1000);
await CancelButton.click(); await CancelButton.click();
/*browser.waitForAngular();//INCONSISTENT /*browser.waitForAngular();//INCONSISTENT
@@ -379,9 +357,9 @@ function InterestSurveyResultsWidgetEdit() {
browser.sleep(1000); browser.sleep(1000);
await SendButton.click(); await SendButton.click();
browser.sleep(2500); browser.sleep(2500);
await expect(DivAlertTitle.getText()).toEqual('Your interest survey results are in flight!'); await expect(DIVAlertTitle.getText()).toEqual('Your interest survey results are in flight!');
await expect(DivAlertMessage.getText()).toEqual('Trouble receiving the email? Have your recipient check their spam folder for an email from hi@journeysmap.com'); await expect(DIVAlertMessage.getText()).toEqual('Trouble receiving the email? Have your recipient check their spam folder for an email from hi@journeysmap.com');
await DivOKButton.click(); await DIVOKButton.click();
browser.waitForAngular(); browser.waitForAngular();
browser.wait(EC.elementToBeClickable(ShareResultsIcon));*/ browser.wait(EC.elementToBeClickable(ShareResultsIcon));*/
browser.waitForAngular(); browser.waitForAngular();
@@ -391,6 +369,8 @@ function InterestSurveyResultsWidgetEdit() {
function InterestSurveyResultsWidgetResults() { function InterestSurveyResultsWidgetResults() {
it(': InterestSurveyResultsWidgetResults, should verify the Interest Survey Clusters widget and jump to learn more page', async function () { it(': InterestSurveyResultsWidgetResults, should verify the Interest Survey Clusters widget and jump to learn more page', async function () {
var ExploreCareersButton = element(by.css('div:nth-child(2) > .btn'));
var CareerExplorationPageTitle = element(by.css('.surveyContainer > .col-xs-offset-1'));
var WidgetTitle = element(by.css('.row > .jrnys_lead-body-copy')); var WidgetTitle = element(by.css('.row > .jrnys_lead-body-copy'));
var WidgetDescription = element(by.css('.row > span:nth-child(2)')); var WidgetDescription = element(by.css('.row > span:nth-child(2)'));
var BusinessManagementAndAdministration = element(by.css('#\\35 db8efa4-0809-4e9e-8096-db5d5d1dafd5 > #territoryCardContainer .territoryCardTitleText > .ng-binding')); var BusinessManagementAndAdministration = element(by.css('#\\35 db8efa4-0809-4e9e-8096-db5d5d1dafd5 > #territoryCardContainer .territoryCardTitleText > .ng-binding'));
@@ -449,6 +429,10 @@ function InterestSurveyResultsWidgetResults() {
var EC = protractor.ExpectedConditions; var EC = protractor.ExpectedConditions;
var AdministrativeServicesManagersJourneyInfoIcon = element(by.css('span > .journey-info-circle')); var AdministrativeServicesManagersJourneyInfoIcon = element(by.css('span > .journey-info-circle'));
await ExploreCareersButton.click().then(function() {
browser.sleep(2500);
});
expect(await CareerExplorationPageTitle.getText()).toEqual('Career Exploration');
expect(await WidgetTitle.getText()).toEqual('Clusters'); expect(await WidgetTitle.getText()).toEqual('Clusters');
expect(await WidgetDescription.getText()).toEqual('To start your career exploration, select a cluster below.'); expect(await WidgetDescription.getText()).toEqual('To start your career exploration, select a cluster below.');
expect(await BusinessManagementAndAdministration.getText()).toEqual('Business Management & Administration'); expect(await BusinessManagementAndAdministration.getText()).toEqual('Business Management & Administration');
@@ -591,6 +575,9 @@ function InterestSurveyResultsWidgetResults() {
await AdministrativeServicesManagersAtAGlanceXCloseIcon.click().then(function() { await AdministrativeServicesManagersAtAGlanceXCloseIcon.click().then(function() {
browser.sleep(2500); browser.sleep(2500);
}); });
browser.executeScript('window.scrollTo(0, 100);').then(function() {
browser.sleep(2500);
});
//expect(await AdministrativeServicesManagersAtAGlanceBestMatchIcon.getText()).toContain('Best Fit'); EDM-1726 //expect(await AdministrativeServicesManagersAtAGlanceBestMatchIcon.getText()).toContain('Best Fit'); EDM-1726
await AdministrativeServicesManagersEllipsis.click().then(function() { await AdministrativeServicesManagersEllipsis.click().then(function() {
browser.sleep(2500); browser.sleep(2500);
@@ -616,9 +603,9 @@ function InterestSurveyResultsCreateJourney() {
it(': InterestSurveyResultsCreateJourney, should create a Journey to Top Interest Survey Result', async function () { it(': InterestSurveyResultsCreateJourney, should create a Journey to Top Interest Survey Result', async function () {
var JourneySideBarHeaderOne = element(by.css('.side-bar-child-text > span')); var JourneySideBarHeaderOne = element(by.css('.side-bar-child-text > span'));
var JourneyInfoIcon = element(by.css('span > .journey-info-circle')); var JourneyInfoIcon = element(by.css('span > .journey-info-circle'));
var JourneyInfoDivTitle = element(by.css('.col-lg-12 > .ng-binding')); var JourneyInfoDIVTitle = element(by.css('.col-lg-12 > .ng-binding'));
var JourneyInfoDivSubText = element(by.css('.col-lg-12:nth-child(3)')); var JourneyInfoDIVSubText = element(by.css('.col-lg-12:nth-child(3)'));
var JourneyInfoDivXCloseIcon = element(by.css('.fa-times')); var JourneyInfoDIVXCloseIcon = element(by.css('.fa-times'));
var JourneyEntryPoint = element(by.css('.journeyInput')); var JourneyEntryPoint = element(by.css('.journeyInput'));
var SelectEntryPointDropDown = element(by.css('.ng-scope:nth-child(1) > .sidebarScrollListTxt > .ng-binding')); var SelectEntryPointDropDown = element(by.css('.ng-scope:nth-child(1) > .sidebarScrollListTxt > .ng-binding'));
var StartYourJourneyButton = element(by.css('.journeyStartBtnEnable')); var StartYourJourneyButton = element(by.css('.journeyStartBtnEnable'));
@@ -641,9 +628,9 @@ function InterestSurveyResultsCreateJourney() {
await JourneyInfoIcon.click().then(function() { await JourneyInfoIcon.click().then(function() {
browser.sleep(1000); browser.sleep(1000);
}); });
expect(await JourneyInfoDivTitle.getText()).toEqual('Create Your Journey'); 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.'); 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() { await JourneyInfoDIVXCloseIcon.click().then(function() {
browser.sleep(1000); browser.sleep(1000);
}); });
await JourneyEntryPoint.click(); await JourneyEntryPoint.click();
@@ -684,6 +671,158 @@ function InterestSurveyResultsCreateJourney() {
}); });
} }
function DeleteCreatedJourney() {
it(': DeleteCreatedJourney, should navigate to My Journeys and delete recently created Journey', async function () {
var MyJourneysHeaderLink = element(by.css('#nbMyJourneys .span-navbar-hover'));
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(.,'9 to Administrative Services Managers through Business Administration B.A./B.S.')]"));
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 TwelvethGradeBubble = element(by.css('#mCSB_1_container > .fullSize-Journey:nth-child(4) .lblClass'));
var BusinessAdministrationBABSBubble = element(by.css('#mCSB_1_container > .fullSize-Journey:nth-child(5) .lblClass:nth-child(1)'));
var AdministrativeServiceManagersBubble = element(by.css('.fullSize-Journey:nth-child(6) .triple-line > .lblClass:nth-child(1)'));
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 JourneysActionTitleHeader = element(by.css('div:nth-child(2) > .ng-binding'));
var ActionTitleBar = element(by.css('#journey-view-single > .side-bar-child-text'));
var EditJourneyLink = element(by.linkText('Edit Journey'));
var JourneyEntryWayPointTopLevel = element(by.css('#journeyViewToolTip_0 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var JourneyEntryWayPointCluster = element(by.css('#journeyViewToolTip_0 .side-bar-journey-detail-child-txt:nth-child(5)'));
var TenthGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_1 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var TenthGradeWayPointCluster = element(by.css('#journeyViewToolTip_1 .side-bar-journey-detail-child-txt:nth-child(5)'));
var EleventhGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_2 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var EleventhGradeWayPointCluster = element(by.css('#journeyViewToolTip_2 .side-bar-journey-detail-child-txt:nth-child(5)'));
var TwelfthGradeWayPointTopLevel = element(by.css('#journeyViewToolTip_3 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var TwelfthGradeWayPointCluster = element(by.css('#journeyViewToolTip_3 .side-bar-journey-detail-child-txt:nth-child(5)'));
var CollegeStopWayPointTopLevel = element(by.css('#journeyViewToolTip_4 .ng-binding:nth-child(1)'));
var CollegeStopWayPointCluster = element(by.css('#journeyViewToolTip_4 > .ng-isolate-scope .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var CollegeStopWayPointPathway = element(by.css('#journeyViewToolTip_4 .side-bar-journey-detail-child-txt:nth-child(5)'));
var JourneyExitWayPointTopLevel = element(by.css('#journeyViewToolTip_5 .ng-binding:nth-child(1)'));
var JourneyExitWayPointCluster = element(by.css('#journeyViewToolTip_5 .sidebarDescriptionAncestorTxt > .sidebarDescriptionAncestorTxt'));
var JourneyExitWayPointPathway = element(by.css('.disableJourneyItem:nth-child(5)'));
var MyJourneysHowAmIDoingButton = element(by.css('.btn-success'));
var MyJourneysSubText = element(by.css('.details-resourceRowTitle'));
var MySavedJourneysTitleOne = element(by.css('#ee7b663d-2f15-43cc-867c-556c7fc493a5 .cursorPointer'));
var MySavedJourneysTitleTwo = element(by.css('#\\30 ac99d25-0cc4-4d8e-b8e4-785f8129d85e .cursorPointer'));
var MySavedJourneysTitleThree = element(by.css('#e0049880-9613-4fd5-9ed2-eb468cdc2e55 .cursorPointer'));
var MySavedJourneysTitleFour = element(by.css('#\\30 9731631-9cb7-449b-8a51-58d7e730e31b .cursorPointer'));
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('9 to Administrative Services Managers through Business Administration B.A./B.S.');
expect(await NinethGradeBubble.getText()).toEqual('9');
expect(await TenthGradeBubble.getText()).toEqual('10');
expect(await EleventhGradeBubble.getText()).toEqual('11');
expect(await TwelvethGradeBubble.getText()).toEqual('12');
expect(await BusinessAdministrationBABSBubble.getText()).toEqual('Business');
expect(await AdministrativeServiceManagersBubble.getText()).toEqual('Administrativ');
await MyJourneysSelectCreatedJourney.click().then(function() {
browser.sleep(2500);
});
expect(await MyJourneysTitleRow.getText()).toEqual('9 to Administrative Services Managers through Business Administration B.A./B.S.');
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('9');
await MyJourneysRightArrow.click().then(function() {
browser.sleep(1500);
});
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('10');
await MyJourneysRightArrow.click().then(function() {
browser.sleep(1500);
});
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('11');
await MyJourneysRightArrow.click().then(function() {
browser.sleep(1500);
});
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('12');
await MyJourneysRightArrow.click().then(function() {
browser.sleep(1500);
});
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('Business Administration B.A./B.S.');
await MyJourneysRightArrow.click().then(function() {
browser.sleep(1500);
});
expect(await MyJourneysWayPointTitleRow.getText()).toEqual('Administrative Services Managers');
await MyJourneysRightArrow.click().then(function() {
browser.sleep(1500);
});
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 MyJourneysViewOnMap.click().then(function() {
browser.sleep(5000);
});
expect(await JourneysActionTitleHeader.getText()).toEqual('Journey View');
expect(await ActionTitleBar.getText()).toEqual('9 to Administrative Services Managers through Business Administration B.A./B.S.');
expect(await EditJourneyLink.getText()).toEqual('Edit Journey');
expect(await JourneyEntryWayPointTopLevel.getText()).toEqual('HS');
expect(await JourneyEntryWayPointCluster.getText()).toEqual('9');
expect(await TenthGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await TenthGradeWayPointCluster.getText()).toEqual('10');
expect(await EleventhGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await EleventhGradeWayPointCluster.getText()).toEqual('11');
expect(await TwelfthGradeWayPointTopLevel.getText()).toEqual('HS');
expect(await TwelfthGradeWayPointCluster.getText()).toEqual('12');
expect(await CollegeStopWayPointTopLevel.getText()).toEqual('College');
expect(await CollegeStopWayPointCluster.getText()).toEqual('Administration');
expect(await CollegeStopWayPointPathway.getText()).toEqual('Business Administration B.A./B.S.');
expect(await JourneyExitWayPointTopLevel.getText()).toEqual('Administration');
expect(await JourneyExitWayPointCluster.getText()).toEqual('Management');
expect(await JourneyExitWayPointPathway.getText()).toEqual('Administrative Services Managers');
await MyJourneysHeaderLink.click().then(function() {
browser.sleep(2500);
});
await MyJourneysSelectCreatedJourney.click().then(function() {
browser.sleep(2500);
});
await MyJourneysHowAmIDoingButton.click().then(function() {
browser.sleep(2500);
});
expect(await MyJourneysDIVTite.getText()).toEqual('Oops!');
expect(await MyJourneysDIVSubText.getText()).toEqual("Sorry, we can't give you a quiz for this.");
expect(await MyJourneysDIVOKButton.getText()).toEqual('OK');
await MyJourneysDIVOKButton.click().then(function() {
browser.sleep(2500);
});
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() { function SignOut() {
it(': SignOut, should log out of journeysmap', async function () { it(': SignOut, should log out of journeysmap', async function () {
var ProfileImage = element(by.css('.roundCenterBackgroundImage')); var ProfileImage = element(by.css('.roundCenterBackgroundImage'));

View File

@@ -3,7 +3,7 @@
exports.config = { exports.config = {
framework: 'jasmine', framework: 'jasmine',
seleniumAddress: 'http://localhost:4444/wd/hub', seleniumAddress: 'http://localhost:4444/wd/hub',
specs: ['profileAndMyProgress_spec.js'], specs: ['profileAndMyProgressWidgets_spec.js'],
jasmineNodeOpts: { jasmineNodeOpts: {
defaultTimeoutInterval: 360000 defaultTimeoutInterval: 360000

View File

@@ -145,7 +145,7 @@ function TopCareerWidget() {
var PersonalityBulletFour = element(by.css('.ng-scope:nth-child(2) > td:nth-child(2) > .ng-binding')); var PersonalityBulletFour = element(by.css('.ng-scope:nth-child(2) > td:nth-child(2) > .ng-binding'));
var PersonalityBulletFive = element(by.css('table:nth-child(1) .ng-scope:nth-child(3) > td:nth-child(1) > .ng-binding:nth-child(2)')); var PersonalityBulletFive = element(by.css('table:nth-child(1) .ng-scope:nth-child(3) > td:nth-child(1) > .ng-binding:nth-child(2)'));
var PersonalityBulletSix = element(by.css('.ng-scope:nth-child(3) > td:nth-child(2) > .ng-binding')); var PersonalityBulletSix = element(by.css('.ng-scope:nth-child(3) > td:nth-child(2) > .ng-binding'));
var WagesWidgetTitle = element(by.xpath('//occupation-wages/div/div[2]/div/div'));//css('.widget-round-corners:nth-child(4) .fullHeight .jrnys_lead-body-copy')); var WagesWidgetTitle = element(by.xpath('//occupation-wages/div/div[2]/div/div'));
var WagesInfoIcon = element(by.css('.jrnys_lead-body-copy > .journey-info-circle')); var WagesInfoIcon = element(by.css('.jrnys_lead-body-copy > .journey-info-circle'));
var WagesWidgetBackOfCardTitle = element(by.css('tr > .jrnys_lead-body-copy')); var WagesWidgetBackOfCardTitle = element(by.css('tr > .jrnys_lead-body-copy'));
var WagesSubTextOne = element(by.css('table:nth-child(2) > tbody > tr:nth-child(2) div:nth-child(1)')); var WagesSubTextOne = element(by.css('table:nth-child(2) > tbody > tr:nth-child(2) div:nth-child(1)'));