From 116aa16a7378bd73e0cdcdf6bad6e78d4c93da94 Mon Sep 17 00:00:00 2001 From: jhuerta Date: Thu, 1 May 2025 15:24:25 -0700 Subject: [PATCH] Completed Framework Management script --- frameworkManagementPageResults.xlsx | Bin 26361 -> 128640 bytes index.js | 14 +- tests/ExACT_frameworkManagementPage.js | 3526 +++++++++++++++++++++++- 3 files changed, 3522 insertions(+), 18 deletions(-) diff --git a/frameworkManagementPageResults.xlsx b/frameworkManagementPageResults.xlsx index 03968328c3b134f28e7dec342ddbe30aa773487f..b019b7907f5fdfdd528a8bc1c76e6ccb28dc6bd1 100644 GIT binary patch literal 128640 zcmeIb-H#+ome5(3X%OnwXm&IpjgSzblwgt2jZAls&!VbEm04BYx4Y`z(yh98nub+u zWJF|UbVWu45s_Jy4M@X)P-{nv1Url10f`4BK&yq305KX3V*iTeWrbGi`49}Nepp^s z+J`;%<$k`*-7W9cu6CI_Q(aabX2;Ebe$4zFGjltyzxz|)_#+R(fB*2Kzy9n0@((r2Kl+6yKmE-|pD$L^0~Fd{Ew}p)NLlY6A6*>| z+lR-;``Ojvdb;m!wu?3Va|V-R1FiI(s+0TpZ^oCxc_CK_%np36a_PWd8VQ z_sKjv>b$+%!kwFCZ!RvDv&FN`?B;s0J}9@a?cZN576%YI-CZsYkB%jx&SX&Wt^@22me_gt@> z0$xv->!Z$kdJQW4nN`rvTl?UjJo3VyuRsshhrPKlTkYPM&a)sTpleJY&fjI`ul?Qr zY_;p$PFJA2%k_No{_Wxe=<{m2Kfn)Rzjyld>}){t+e|M1K;(Zh91nUl zzs+>DTCU%T+~$G4c;Tg&SuQrKZ>!lykbQLGvsbx58%pgmx477>4>4W4p8jC7djT0t zMl(jQI|mqqFQzll;EV^ZDi)+GfGfnlH|GX(irXO_!v^^a^AvqMskGNXAd^rYkMq>4L)h zatDKlmhoFRKOl8|bG5rUER{Qd_v)Hte6`uEPB%Lhz<15P5aG8s>r4ISyBnPE^Xc?f zyZ702O&;y@n=Oo*K`9CQv#SNE=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zi>qt9d>0B#cX!?EDR>mm*VFUW0nTZU+PZEOp3T`#eP+ES>lgt@MlxLjVSCCqib#Nt{n z@!@0hi(ck^w2b*hFY|+~-j*M17qQ0JpS1SZlsQBI!1Y+o>`&TlYRYWqoEq*X=2xA< z4vbj#fN()YkNx;;%-_mF|1-WLeg;zoyXAb*G4D2Kq#tw3hqkQYZmidkIRf8tO($(} zfA?Z{GcB1l!M?tV7|YJeZ>YxsCO;O(_J6;66|9(s8}1KxU}}8Lt#v}{?i{SR${9#v z9aM}t8?EjL`t+5Xt5~*m_hxfuY2B$=!Na6VsKT**se={q5x54`Ox{2I=&%3!zl1C1 z&mRLjg8m0}bZ#qlLaYnR<(&M?kKX;eKmOo>`D5&n>c9UTB!e8T#9Y7^|LGgQ`u%T! zWeIpiGQ>GjgKCfKR-{3{?$Kei%uO{jn{K0rJ9prl2bP-QWHQ&l~W9+}o=P{?EVrk?{R^X>Q9`r91xt rl@69YFU~E{s`x+oy^l0|^!0cD;2$!Xz6t;Lmq00g@_&F6@!V`rb-J@?$dG)H%FZw757DWVybaITom~$ZF-nfpT$Y$pv=$ko3vF&8Oa3*!Q+<9?UFwaginbs5LigSo= zb74)Rn$Dc}!}nETEh6hwmQClJ+~CEGtIjVPP5EAHE*-u3_jL_m5?&z&OTIH|y$!u11tq>DySp~~0e(~lC2_Ze5^WT$reP=A1Z$CKHnNW3H=ndVW>LOGkJ$UsY zqpLc`sjTXIqT%Oa(Qy7&Cb^Mm7AH&Ok)=&PkW)?dRew9Nyhd`qg9Stk)+Zb}mQ r%EK2qNi3`r-Dk~6;?g=9^u4`D5-rzB)Yti_Bz9jX+x<@zr1JF-Jf@P; diff --git a/index.js b/index.js index 04d38ea..6a2ee76 100644 --- a/index.js +++ b/index.js @@ -24,27 +24,27 @@ app.get('/', (req, res) => {

    ExACT Automated Regression Scripts

    (Click the corresponding link to execute the desired script)
    -
    +


    DASHBOARD

    - +

    CONTENT

    - +

    ALIGN

    - + +
    -
    -
    +
    -
    +

    FRAMEWORKS

    diff --git a/tests/ExACT_frameworkManagementPage.js b/tests/ExACT_frameworkManagementPage.js index ea13f67..a07bd40 100644 --- a/tests/ExACT_frameworkManagementPage.js +++ b/tests/ExACT_frameworkManagementPage.js @@ -4,7 +4,7 @@ import XLSX from 'xlsx'; import path from 'path'; const ExACT_frameworkManagementPage = (req, res) => { - res.send('

    ExACT Automated Test Script - Framework Management Page: Initiated

    '); + res.send('

    ExACT Automated Test Script: Framework Management Page(ExACT_frameworkManagementPage); Initiated

    '); (async function example() { let driver = await new Builder().forBrowser('chrome').build(); let testStatus = 'Failed'; @@ -71,7 +71,7 @@ const steps = [ action: async () => { const elementText = await driver.findElement(By.css('h2')).getText(); if (elementText !== 'Framework Management') { - throw new Error(`Expected: "Framework Management"; Actual: "${elementText}"`); + throw new Error(`Expected: "Framework Management" page title; Actual: "${elementText}"`); } console.log('Passed: Framework Management page title matched as expected'); } @@ -121,7 +121,7 @@ const steps = [ if (elementText !== 'Publishing') { throw new Error(`Expected: "Publishing" button text; Actual: "${elementText}"`); } - console.log('Passed: Publsining button text matched as expected'); + console.log('Passed: Publishging button text matched as expected'); } }, @@ -137,6 +137,44 @@ const steps = [ } }, + //NEXT ACTION - Click Publishing button + { description: 'Click Publishing button', action: async () => await driver.findElement(By.linkText('Publishing')).click() }, + + //Publishing Page + { + description: 'Wait for Publishing page to load', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('h2')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Publishing page did not load'); + } + console.log('Passed: Publishing page loaded'); + } + }, + + //Framework Publishing page title + { + description: 'Validate Framework Publishing page title', + action: async () => { + const elementText = await driver.findElement(By.css('h2')).getText(); + if (elementText !== 'Framework Publishing') { + throw new Error(`Expected: "Framework Publishing" page title text; Actual: "${elementText}"`); + } + console.log('Passed: Framework Publishing page title text matched as expected'); + } + }, + + //NEXT ACTION - Navigate to Framework Management page + { description: 'Click Frameworks navigation link', action: async () => await driver.findElement(By.linkText('Frameworks')).click() }, + + //Wait for page to load - Correlation Coverages View Details button + { + description: 'Wait for page to load', + action: async () => { + return await driver.wait(until.elementLocated(By.css('h2')), 10000).catch(() => false); + } + }, + //Import Framework button icon { description: 'Verify Import Framework buttion icon is present', @@ -173,6 +211,257 @@ const steps = [ } }, + //NEXT ACTION - Click Import Framework button + { description: 'Click Import Framework button', action: async () => await driver.findElement(By.linkText('Import Framework')).click() }, + + //Import Framework DIV + { + description: 'Wait for Import Framework DIV to open', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.modal-lg .modal-title')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Import Framework DIV did not open'); + } + console.log('Passed: Import Framework DIV opened'); + } + }, + + //Import Framework DIV title + { + description: 'Validate Import Framework DIV title', + action: async () => { + const elementText = await driver.findElement(By.css('.modal-lg .modal-title')).getText(); + if (elementText !== 'Import Framework') { + throw new Error(`Expected: "Import Framework" DIV title text; Actual: "${elementText}"`); + } + console.log('Passed: Import Framework DIV title text matched as expected'); + } + }, + + //X icon DIV color -red + { + description: 'Validate X icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-lg .modal-header span')).getCssValue('color'); + if (elementStyle !== 'rgba(246, 60, 40, 1)') { + throw new Error(`DIV "X" icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV X icon color matched as expected'); + } + }, + + //Import Into label + { + description: 'Validate Import Into label', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype > .form-label')).getText(); + if (elementText !== 'Import Into') { + throw new Error(`Expected: "Import Into" label text; Actual: "${elementText}"`); + } + console.log('Passed: Import Into label text matched as expected'); + } + }, + + //Import Into dropdown "New = { + const elementOption = await driver.findElement(By.css('#target')).getAttribute('value'); + if (elementOption !== 'new') { + throw new Error(`Expected: ""; Actual: "${elementOption}"`); + } + console.log('Passed: dropdown option matched as expected'); + } + }, + + //Name label + { + description: 'Validate Name label', + action: async () => { + const elementText = await driver.findElement(By.css('#divname > .form-label')).getText(); + if (elementText !== 'Name') { + throw new Error(`Expected: "Name" label text; Actual: "${elementText}"`); + } + console.log('Passed: Name label text matched as expected'); + } + }, + + //Name textbox + { + description: 'Validate Name textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#orgname')).getText(); + if (elementValue !== '') { + throw new Error(`Expected: "Blank" Name textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Blank Name textbox value matched as expected'); + } + }, + + //Upload File label + { + description: 'Validate Upload File label', + action: async () => { + const elementText = await driver.findElement(By.css('#divupload > .form-label')).getText(); + if (elementText !== 'Upload File') { + throw new Error(`Expected: "Upload File" label text; Actual: "${elementText}"`); + } + console.log('Passed: Upload File label text matched as expected'); + } + }, + + //Upload File type + { + description: 'Validate Upload File type', + action: async () => { + const elementText = await driver.findElement(By.css('#upload')).getAttribute('type'); + if (elementText !== 'file') { + throw new Error(`Expected: "file" type; Actual: "${elementText}"`); + } + console.log('Passed: File type matched as expected'); + } + }, + + //Parent label + { + description: 'Validate Parent label', + action: async () => { + const elementText = await driver.findElement(By.css('#divparent > .form-label')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "Parent" label text; Actual: "${elementText}"`); + } + console.log('Passed: Parent label text matched as expected'); + } + }, + + //Parent dropdown + { + description: 'Validate Parent dropdown', + action: async () => { + const elementText = await driver.findElement(By.css('#parent > option:nth-child(1)')).getText(); + if (elementText !== 'None') { + throw new Error(`Expected: Parent dropdown "None" default text; Actual: "${elementText}"`); + } + console.log('Passed: Parent dropdown None default text matched as expected'); + } + }, + + //Download Import Template button icon + { + description: 'Verify Download Import Template buttion icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.mr-auto > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Download Import Template button icon not found'); + } + console.log('Passed: Download Import Template button icon present'); + } + }, + + //Download Import Template button text + { + description: 'Validate Download Import Template button text', + action: async () => { + const elementText = await driver.findElement(By.linkText('Download Import Template')).getText(); + if (elementText !== 'Download Import Template') { + throw new Error(`Expected: "Download Import Template" button text; Actual: "${elementText}"`); + } + console.log('Passed: Download Import Template button text matched as expected'); + } + }, + + //Download Import Template button color -green + { + description: 'Validate Download Import Template button color', + action: async () => { + const elementStyle = await driver.findElement(By.linkText('Download Import Template')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Download Import Template button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Download Import Template button color matched as expected'); + } + }, + + //Import button text + { + description: 'Validate Import button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalop')).getAttribute('value'); + if (elementText !== 'Import') { + throw new Error(`Expected: "Import" button text; Actual: "${elementText}"`); + } + console.log('Passed: Import button text matched as expected'); + } + }, + + //Import button color -green + { + description: 'Validate Import button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalop')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Import button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Import button color matched as expected'); + } + }, + + //Close button text + { + description: 'Validate Close button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalclose')).getText(); + if (elementText !== 'Close') { + throw new Error(`Expected: "Close" button text; Actual: "${elementText}"`); + } + console.log('Passed: Close button text matched as expected'); + } + }, + + //Close button color -white + { + description: 'Validate Close button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalclose')).getCssValue('background-color'); + if (elementStyle !== 'rgba(0, 0, 0, 0)') { + throw new Error(`Close button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Close button color matched as expected'); + } + }, + + //NEXT ACTION - Import Framework DIV validation + { description: 'Click Import button', action: async () => await driver.findElement(By.css('#modalop')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //Valiation text + { + description: 'Validattion text', + action: async () => { + const elementText = await driver.findElement(By.css('b')).getText(); + if (elementText !== 'Please enter a value for all highlighted fields') { + throw new Error(`Expected: "Please enter a value for all highlighted fields" validation text; Actual: "${elementText}"`); + } + console.log('Passed: Validation text matched as expected'); + } + }, + + //Validation text color -red + { + description: 'Validate text color', + action: async () => { + const elementStyle = await driver.findElement(By.css('b')).getCssValue('color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`Validation text color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Validation text color matched as expected'); + } + }, + + //NEXT ACTION - DIV X-Close Icon + { description: 'Click DIV X icon', action: async () => await driver.findElement(By.css('.modal-lg .modal-header span')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + //Create button icon { description: 'Verify Create buttion icon is present', @@ -209,6 +498,209 @@ const steps = [ } }, + //NEXT ACTION - Click Create button + { description: 'Click Create button', action: async () => await driver.findElement(By.linkText('Create')).click() }, + + //Create DIV + { + description: 'Wait for Create DIV to load', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.modal-lg .modal-title')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Create DIV did not load'); + } + console.log('Passed: Create DIV loaded'); + } + }, + + //Create DIV title + { + description: 'Validate Create DIV title', + action: async () => { + const elementText = await driver.findElement(By.css('.modal-lg .modal-title')).getText(); + if (elementText !== 'Create Organization/Framework') { + throw new Error(`Expected: "Create Organization/Framework" DIV title text; Actual: "${elementText}"`); + } + console.log('Passed: Create Organization/Framework DIV title text matched as expected'); + } + }, + + //X icon DIV color -red + { + description: 'Validate X icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-lg .modal-header span')).getCssValue('color'); + if (elementStyle !== 'rgba(246, 60, 40, 1)') { + throw new Error(`DIV "X" icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV X icon color matched as expected'); + } + }, + + //Type label + { + description: 'Validate Type label', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype > .form-label')).getText(); + if (elementText !== 'Type') { + throw new Error(`Expected: "Type" label text; Actual: "${elementText}"`); + } + console.log('Passed: Type label text matched as expected'); + } + }, + + //Type dropdown (C= Organization) + { + description: 'Validate Type dropdown option', + action: async () => { + const elementOption = await driver.findElement(By.css('#orgtype')).getAttribute('value'); + if (elementOption !== 'C') { + throw new Error(`Expected: "Organization"; Actual: "${elementOption}"`); + } + console.log('Passed: Organization dropdown option matched as expected'); + } + }, + + //Name label + { + description: 'Validate Name label', + action: async () => { + const elementText = await driver.findElement(By.css('#divname > .form-label')).getText(); + if (elementText !== 'Name') { + throw new Error(`Expected: "Name" label text; Actual: "${elementText}"`); + } + console.log('Passed: Name label text matched as expected'); + } + }, + + //Name textbox + { + description: 'Validate Name textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#orgname')).getText(); + if (elementValue !== '') { + throw new Error(`Expected: "Blank" Name textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Blank Name textbox value matched as expected'); + } + }, + + //Notes label + { + description: 'Validate Notes label', + action: async () => { + const elementText = await driver.findElement(By.css('#divnotes > .form-label')).getText(); + if (elementText !== 'Notes') { + throw new Error(`Expected: "Notes" label text; Actual: "${elementText}"`); + } + console.log('Passed: Notes label text matched as expected'); + } + }, + + //Notes textbox + { + description: 'Validate Notes textbox', + action: async () => { + const elementText = await driver.findElement(By.css('#notes')).getText(); + if (elementText !== '') { + throw new Error(`Expected: "Blank" Notes textbox value; Actual: "${elementText}"`); + } + console.log('Passed: Blank Notes textboxd value matched as expected'); + } + }, + + //Notes textbox + { + description: 'Validate Notes textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#notes')).getText(); + if (elementValue !== '') { + throw new Error(`Expected: "Blank" Notes textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Blank Notes textbox value matched as expected'); + } + }, + + //Create button text + { + description: 'Validate Create button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalop')).getAttribute('value'); + if (elementText !== 'Create') { + throw new Error(`Expected: "Create" button text; Actual: "${elementText}"`); + } + console.log('Passed: Create button text matched as expected'); + } + }, + + //Create button color -green + { + description: 'Validate Create button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalop')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Create button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Create button color matched as expected'); + } + }, + + //Close button text + { + description: 'Validate Close button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalclose')).getText(); + if (elementText !== 'Close') { + throw new Error(`Expected: "Close" button text; Actual: "${elementText}"`); + } + console.log('Passed: Close button text matched as expected'); + } + }, + + //Close button color -white + { + description: 'Validate Close button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalclose')).getCssValue('background-color'); + if (elementStyle !== 'rgba(0, 0, 0, 0)') { + throw new Error(`Close button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Close button color matched as expected'); + } + }, + + //NEXT ACTION - Create DIV validation + { description: 'Click Import button', action: async () => await driver.findElement(By.css('#modalop')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //Valiation text + { + description: 'Validattion text', + action: async () => { + const elementText = await driver.findElement(By.css('b')).getText(); + if (elementText !== 'Please enter a value for all highlighted fields') { + throw new Error(`Expected: "Please enter a value for all highlighted fields" validation text; Actual: "${elementText}"`); + } + console.log('Passed: Validation text matched as expected'); + } + }, + + //Validation text color -red + { + description: 'Validate text color', + action: async () => { + const elementStyle = await driver.findElement(By.css('b')).getCssValue('color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`Validation text color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Validation text color matched as expected'); + } + }, + + //NEXT ACTION - DIV Close button + { description: 'Click DIV Close icon', action: async () => await driver.findElement(By.css('#modalclose')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + //Search textbox { description: 'Verify Search textbox is present', @@ -257,25 +749,3022 @@ const steps = [ } }, - //Advanced Search button color -green (slightly different green color) + //Advanced Search button color -green (ECS-2894) { description: 'Validate Advanced Search button color', action: async () => { const elementStyle = await driver.findElement(By.css('.bg-green')).getCssValue('background-color'); - if (elementStyle !== 'rgba(26, 187, 156, 1)') { - throw new Error(`Advanced Search button color did not match; Actual: "${elementStyle}"`); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`ECS-2894 Advanced Search button color did not match; Actual: "${elementStyle}"`); } - console.log('Passed: Advanced Search button color matched as expected'); + console.log('Passed: ECS-2894 Advanced Search button color matched as expected'); + } + }, + + //NEXT ACTION - Advanced Search button + { description: 'Click Advanced Search button', action: async () => await driver.findElement(By.css('.bg-green')).click() }, + + //Advanced Search DIV + { + description: 'Wait for Advanced Search DIV to load', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#exampleModalCenterTitle')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Advanced Search DIV did not load'); + } + console.log('Passed: Advanced Search DIV loaded'); + } + }, + + //Advanced Search DIV title + { + description: 'Validate Advanced Search DIV title', + action: async () => { + const elementText = await driver.findElement(By.css('#exampleModalCenterTitle')).getText(); + if (elementText !== 'Advance Framework Search') { + throw new Error(`Expected: "Advance Framework Searchh" DIV title text; Actual: "${elementText}"`); + } + console.log('Passed: Advance Framework Search DIV title text matched as expected'); + } + }, + + //X icon DIV color -red + { + description: 'Validate X icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-dialog-centered .modal-header span')).getCssValue('color'); + if (elementStyle !== 'rgba(246, 60, 40, 1)') { + throw new Error(`DIV "X" icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV X icon color matched as expected'); + } + }, + + //Search in handle + { + description: 'Validate Search in handle', + action: async () => { + const elementText = await driver.findElement(By.css('.col-sm-12:nth-child(1) > label')).getText(); + if (elementText !== 'Search in') { + throw new Error(`Expected: "Search in" handle text; Actual: "${elementText}"`); + } + console.log('Passed: Search in handle text matched as expected'); + } + }, + + //Search in dropdown text + { + description: 'Validate Search in dropdown option', + action: async () => { + const elementOption = await driver.findElement(By.css('#feild')).getAttribute('value'); + if (elementOption !== 'stdtext') { + throw new Error(`Expected: "Item Text"; Actual: "${elementOption}"`); + } + console.log('Passed: Item Text dropdown option matched as expected'); + } + }, + + //Search term textbox -placeholder + { + description: 'Validate Search term textbox placeholder', + action: async () => { + const elementValue = await driver.findElement(By.css('#searchterm')).getAttribute('placeholder'); + if (elementValue !== 'Enter a search term') { + throw new Error(`Expected: Search term "Enter a search term" textbox placeholder; Actual: "${elementValue}"`); + } + console.log('Passed: Enter a search term textbox placeholder matched as expected'); + } + }, + + //Match phrase checkbox + { + description: 'Verify Match phrase checkbox is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.col-sm-12:nth-child(3) > input')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Match exact phrase checkbox not found'); + } + console.log('Passed: Match exact phrase checkbox present'); + } + }, + + //Match exact phrase label (ECS-2893) + { + description: 'Validate Match exact phrase label', + action: async () => { + const elementText = await driver.findElement(By.css('.ml-2:nth-child(2)')).getText(); + if (elementText !== 'Match exact phrase') { + throw new Error(`Expected: ECS-2893 "Match exact phrase" label; Actual: "${elementText}"`); + } + console.log('Passed: ECS-2893 Match exact phrase label matched as expected'); + } + }, + + //Filter By text + { + description: 'Validate Filter By text', + action: async () => { + const elementText = await driver.findElement(By.css('.col-sm-12:nth-child(4) > label')).getText(); + if (elementText !== 'Filter By') { + throw new Error(`Expected: "Filter By" text; Actual: "${elementText}"`); + } + console.log('Passed: Filter By text matched as expected'); + } + }, + + //Framework label + { + description: 'Validate Framework label', + action: async () => { + const elementText = await driver.findElement(By.css('.col-sm-6:nth-child(1) > label')).getText(); + if (elementText !== 'Framework') { + throw new Error(`Expected: "Framework" label; Actual: "${elementText}"`); + } + console.log('Passed: Framework label matched as expected'); + } + }, + + //Framework textbox -placeholder + { + description: 'Validate Framework textbox placeholder', + action: async () => { + const elementValue = await driver.findElement(By.css('#framesearch > div.modal-body > div.row.mt-2 > div:nth-child(1) > span > span.selection > span > span > textarea')).getAttribute('placeholder'); + if (elementValue !== 'All Framework') { + throw new Error(`Expected: Framework "All Framework" textbox placeholder; Actual: "${elementValue}"`); + } + console.log('Passed: Framework All Framework textbox placeholder matched as expected'); + } + }, + + //Level label + { + description: 'Validate Level label', + action: async () => { + const elementText = await driver.findElement(By.css('.col-sm-6:nth-child(2) > label')).getText(); + if (elementText !== 'Level') { + throw new Error(`Expected: "Level" label; Actual: "${elementText}"`); + } + console.log('Passed: Level label matched as expected'); + } + }, + + //Level textbox -value + { + description: 'Validate Level textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#level')).getAttribute('value'); + if (elementValue !== 'all') { + throw new Error(`Expected: Level "All" textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Level All textbox value matched as expected'); + } + }, + + //Subject label + { + description: 'Validate Subject label', + action: async () => { + const elementText = await driver.findElement(By.css('.col-sm-6:nth-child(3) > label')).getText(); + if (elementText !== 'Subject') { + throw new Error(`Expected: "Subject" label; Actual: "${elementText}"`); + } + console.log('Passed: Subject label matched as expected'); + } + }, + + //Subject textbox -placeholder + { + description: 'Validate Subject textbox placeholder', + action: async () => { + const elementValue = await driver.findElement(By.css('#subject > span > span.selection > span > span > textarea')).getAttribute('placeholder'); + if (elementValue !== 'All Subject') { + throw new Error(`Expected: Subject "All Subject" textbox placeholder; Actual: "${elementValue}"`); + } + console.log('Passed: Subjectd All Subject textbox placeholder matched as expected'); + } + }, + + //Grade label + { + description: 'Validate Grade label', + action: async () => { + const elementText = await driver.findElement(By.css('.col-sm-6:nth-child(4) > label')).getText(); + if (elementText !== 'Grade') { + throw new Error(`Expected: "Grade" label; Actual: "${elementText}"`); + } + console.log('Passed: Grade label matched as expected'); + } + }, + + //Grade textbox -placeholder + { + description: 'Validate Grade textbox placeholder', + action: async () => { + const elementValue = await driver.findElement(By.css('#grade > span > span.selection > span > span > textarea')).getAttribute('placeholder'); + if (elementValue !== ' All Grade') { + throw new Error(`Expected: Grade "All Grade" textbox placeholder; Actual: "${elementValue}"`); + } + console.log('Passed: Grade All Grade textbox placeholder matched as expected'); + } + }, + + //Close button text + { + description: 'Validate Close button text', + action: async () => { + const elementText = await driver.findElement(By.css('.btn-secondary:nth-child(1)')).getText(); + if (elementText !== 'Close') { + throw new Error(`Expected: "Close" button text; Actual: "${elementText}"`); + } + console.log('Passed: Close button text matched as expected'); + } + }, + + //Close button color -white + { + description: 'Validate Close button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.btn-secondary:nth-child(1)')).getCssValue('background-color'); + if (elementStyle !== 'rgba(0, 0, 0, 0)') { + throw new Error(`Close button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Close button color matched as expected'); + } + }, + + //Submit button text + { + description: 'Validate Submit button text', + action: async () => { + const elementText = await driver.findElement(By.css('.modal-footer:nth-child(2) > .btn-primary')).getText(); + if (elementText !== 'Submit') { + throw new Error(`Expected: "Submit" button text; Actual: "${elementText}"`); + } + console.log('Passed: Submit button text matched as expected'); + } + }, + + //Submit button color -green + { + description: 'Validate Submit button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-footer:nth-child(2) > .btn-primary')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Submit button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Submit button color matched as expected'); + } + }, + + //NEXT ACTION - Advance Framework Search DIV validation + { description: 'Click Submit button', action: async () => await driver.findElement(By.css('.modal-footer:nth-child(2) > .btn-primary')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - DIV Close button + { description: 'Click DIV Close icon', action: async () => await driver.findElement(By.css('.modal-dialog-centered .modal-header span')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //FRAMEWORK LIST: 4Folder + 6files + //File icon 1 + { + description: 'Verify File icon 1 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.org:nth-child(1) > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('File icon 1 not found'); + } + console.log('Passed: File icon 1 present'); + } + }, + + //Framework 1 title + { + description: 'Validate Framework 1 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('5th Grade Import ECS-2732')).getText(); + if (elementText !== '5th Grade Import ECS-2732') { + throw new Error(`Expected: "5th Grade Import ECS-2732" title text; Actual: "${elementText}"`); + } + console.log('Passed: 5th Grade Import ECS-2732 title text matched as expected'); + } + }, + + //Folder icon 1 + { + description: 'Verify Folder icon 1 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#folder874461689')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Folder icon 1 not found'); + } + console.log('Passed: Folder icon 1 present'); + } + }, + + //Framework 2 title + { + description: 'Validate Framework 2 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('Adding a New Org to test with')).getText(); + if (elementText !== 'Adding a New Org to test with') { + throw new Error(`Expected: "Adding a New Org to test with" title text; Actual: "${elementText}"`); + } + console.log('Passed: Adding a New Org to test with title text matched as expected'); + } + }, + + //Folder icon 2 + { + description: 'Verify Folder icon 2 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#folder874452736')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Folder icon 2 not found'); + } + console.log('Passed: Folder icon 2 present'); + } + }, + + //Framework 3 title + { + description: 'Validate Framework 3 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('ECS-2732 Testing Frame II')).getText(); + if (elementText !== 'ECS-2732 Testing Frame II') { + throw new Error(`Expected: "ECS-2732 Testing Frame II" title text; Actual: "${elementText}"`); + } + console.log('Passed: ECS-2732 Testing Frame II title text matched as expected'); + } + }, + + //File icon 2 + { + description: 'Verify File icon 2 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(4) > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('File icon 2 not found'); + } + console.log('Passed: File icon 2 present'); + } + }, + + //Framework 4 title + { + description: 'Validate Framework 4 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('Kathleen Test')).getText(); + if (elementText !== 'Kathleen Test') { + throw new Error(`Expected: "Kathleen Test" title text; Actual: "${elementText}"`); + } + console.log('Passed: Kathleen Test title text matched as expected'); + } + }, + + //Folder icon 3 + { + description: 'Verify Folder icon 3 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#folder873575829')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Folder icon 3 not found'); + } + console.log('Passed: Folder icon 3 present'); + } + }, + + //Framework 5 title + { + description: 'Validate Framework 5 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('Latest Test For Today')).getText(); + if (elementText !== 'Latest Test For Today') { + throw new Error(`Expected: "Latest Test For Today" title text; Actual: "${elementText}"`); + } + console.log('Passed: Latest Test For Today title text matched as expected'); + } + }, + + //Folder icon 4 + { + description: 'Verify Folder icon 4 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#folder873617737')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Folder icon 4 not found'); + } + console.log('Passed: Folder icon 4 present'); + } + }, + + //Framework 6 title + { + description: 'Validate Framework 6 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('My Latest Organization For Now')).getText(); + if (elementText !== 'My Latest Organization For Now') { + throw new Error(`Expected: "My Latest Organization For Now" title text; Actual: "${elementText}"`); + } + console.log('Passed: My Latest Organization For Now title text matched as expected'); + } + }, + + //File icon 3 + { + description: 'Verify File icon 3 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(7) > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('File icon 3 not found'); + } + console.log('Passed: File icon 3 present'); + } + }, + + //Framework 7 title + { + description: 'Validate Framework 7 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('Stats Test Framework')).getText(); + if (elementText !== 'Stats Test Framework') { + throw new Error(`Expected: "Stats Test Framework" title text; Actual: "${elementText}"`); + } + console.log('Passed: Stats Test Framework title text matched as expected'); + } + }, + + //File icon 4 + { + description: 'Verify File icon 4 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(8) > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('File icon 4 not found'); + } + console.log('Passed: File icon 4 present'); + } + }, + + //Framework 8 title + { + description: 'Validate Framework 8 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('Test Math: Grade 9')).getText(); + if (elementText !== 'Test Math: Grade 9') { + throw new Error(`Expected: "Test Math: Grade 9" title text; Actual: "${elementText}"`); + } + console.log('Passed: Test Math: Grade 9 title text matched as expected'); + } + }, + + //File icon 5 + { + description: 'Verify File icon 5 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(9) > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('File icon 5 not found'); + } + console.log('Passed: File icon 5 present'); + } + }, + + //Framework 9 title + { + description: 'Validate Framework 9 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('Thursday Framework')).getText(); + if (elementText !== 'Thursday Framework') { + throw new Error(`Expected: "Thursday Framework" title text; Actual: "${elementText}"`); + } + console.log('Passed: Thursday Framework title text matched as expected'); + } + }, + + //File icon 6 + { + description: 'Verify File icon 6 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(10) > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('File icon 6 not found'); + } + console.log('Passed: File icon 6 present'); + } + }, + + //Framework 10 title + { + description: 'Validate Framework 10 title', + action: async () => { + const elementText = await driver.findElement(By.linkText('Widget Test')).getText(); + if (elementText !== 'Widget Test') { + throw new Error(`Expected: "Widget Test" title text; Actual: "${elementText}"`); + } + console.log('Passed: Widget Test title text matched as expected'); + } + }, + + //NEXT ACTION - Click My Latest Organization For Now link + { description: 'Click My Latest Organization For Now link', action: async () => await driver.findElement(By.linkText('My Latest Organization For Now')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //My Latest Organization For Now Open file icon is present + { + description: 'Verify My Latest Organization For Now Open file icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#folder873617737')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('My Latest Organization For Now Open file icon is not present'); + } + console.log('Passed: My Latest Organization For Now Open file icon is present'); + } + }, + + //Juan Testing Again & Again Edit icon is present + { + description: 'Verify My Latest Organization For Now Edit icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(6) > .opts .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('My Latest Organization For Now Edit icon is not present'); + } + console.log('Passed: My Latest Organization For Now Edit icon is present'); + } + }, + + //At the Office File icon is present + { + description: 'Verify At the Office File icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#org-873617737 > .list-group-item:nth-child(1) > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('At the Office File icon is not present'); + } + console.log('Passed: At the Office File icon is present'); + } + }, + + //At the Office title + { + description: 'Validate At the Office title', + action: async () => { + const elementText = await driver.findElement(By.linkText('At The Office')).getText(); + if (elementText !== 'At The Office') { + throw new Error(`Expected: "At The Office" title text; Actual: "${elementText}"`); + } + console.log('Passed: At The Office title text matched as expected'); + } + }, + + //Juan Testing Again & Again File icon is present + { + description: 'Verify Juan Testing Again & Again File icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.doc:nth-child(2) > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Juan Testing Again & Again File icon is not present'); + } + console.log('Passed: Juan Testing Again & Again File icon is present'); + } + }, + + //Juan Testing Again & Again title + { + description: 'Validate Juan Testing Again & Again title', + action: async () => { + const elementText = await driver.findElement(By.linkText('Juan Testing Again & Again')).getText(); + if (elementText !== 'Juan Testing Again & Again') { + throw new Error(`Expected: "Juan Testing Again & Again" title text; Actual: "${elementText}"`); + } + console.log('Passed: Juan Testing Again & Again title text matched as expected'); + } + }, + + //NEXT ACTION - Click My Latest Organization For Now Edit icon + { description: 'Click My Latest Organization For Now Edit icon', action: async () => await driver.findElement(By.css('.list-group-item:nth-child(6) > .opts .fa')).click() }, + + //Organization DIV + { + description: 'Wait for Edit Organization DIV to open', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.modal-lg .modal-title')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Edit Organization DIV did not open'); + } + console.log('Passed: Edit Organization DIV opened'); + } + }, + + //Edit Organization title + { + description: 'Validate Edit Organization DIV title', + action: async () => { + const elementText = await driver.findElement(By.css('.modal-lg .modal-title')).getText(); + if (elementText !== 'Edit Organization') { + throw new Error(`Expected: "Edit Organization" DIV title text; Actual: "${elementText}"`); + } + console.log('Passed: Edit Organization DIV title text matched as expected'); + } + }, + + //X icon DIV color -red + { + description: 'Validate X icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-lg .modal-header span')).getCssValue('color'); + if (elementStyle !== 'rgba(246, 60, 40, 1)') { + throw new Error(`DIV "X" icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV X icon color matched as expected'); + } + }, + + //Type label + { + description: 'Validate Type label', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype > .form-label')).getText(); + if (elementText !== 'Type') { + throw new Error(`Expected: "Type" label text; Actual: "${elementText}"`); + } + console.log('Passed: Type label text matched as expected'); + } + }, + + //Type Info icon is present + { + description: 'Verify Type Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('a:nth-child(2) > .fa-question-circle')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Type Info icon is not present'); + } + console.log('Passed: Type Info icon is present'); + } + }, + + //Organization label + { + description: 'Validate Organization label', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype')).getText(); + if (elementText !== 'Organization') { + throw new Error(`Expected: "Organization" label text; Actual: "${elementText}"`); + } + console.log('Passed: Organization label text matched as expected'); + } + }, + + //Fixes are made for text comparison for description text + { + description: 'Validate Applications of Linear Systems description text', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype')).getText(); + const expectedText = 'Organization'; + + // Trim the element text to avoid mismatch due to extra spaces or appended text + if (elementText.trimEnd() !== expectedText) { + throw new Error(`Expected: "${expectedText}" text; Actual: "${elementText}"`); + } + + console.log('Passed: text matched as expected'); } }, + //Organization label + { + description: 'Validate Organization label', + action: async () => { + const elementText = await driver.findElement(By.css('#divname')).getText(); + const expectedText = 'Ogranization'; + //Trim expected text + if (elementText.trimStart() !== expectedText) { + throw new Error(`Expected: "${expectedText}" label text; Actual: "${elementText}"`); + } + console.log(`Passed: "${expectedText}" label text matched as expected`); + } + }, + //Name label + { + description: 'Validate Name label', + action: async () => { + const elementText = await driver.findElement(By.css('#divname > .form-label')).getText(); + if (elementText !== 'Name') { + throw new Error(`Expected: "Name" label text; Actual: "${elementText}"`); + } + console.log('Passed: Name label text matched as expected'); + } + }, + + //Name textbox + { + description: 'Validate Name textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#orgname')).getAttribute('value'); + if (elementValue !== 'My Latest Organization For Now') { + throw new Error(`Expected: Name textbox, "My Latest Organization For Now" value; Actual: "${elementValue}"`); + } + console.log('Passed: Name textbox, My Latest Organization For Now value matched as expected'); + } + }, + + //Notes label + { + description: 'Validate Notes label', + action: async () => { + const elementText = await driver.findElement(By.css('#divnotes > .form-label')).getText(); + if (elementText !== 'Notes') { + throw new Error(`Expected: "Notes" label text; Actual: "${elementText}"`); + } + console.log('Passed: Notes label text matched as expected'); + } + }, + + //Notes textbox + { + description: 'Validate Notes textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#notes')).getText(); + if (elementValue !== 'Would this make a difference.') { + throw new Error(`Expected: Notest textbox, "Would this make a difference." value; Actual: "${elementValue}"`); + } + console.log('Passed: Notes textbox, Would this make a difference. value matched as expected'); + } + }, + + //Delete button text + { + description: 'Validate Delete button text', + action: async () => { + const elementText = await driver.findElement(By.css('#orgdelete')).getText(); + if (elementText !== 'Delete') { + throw new Error(`Expected: "Delete" button text; Actual: "${elementText}"`); + } + console.log('Passed: Delete button text matched as expected'); + } + }, + + //Delete button color -red + { + description: 'Validate Delete button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#orgdelete')).getCssValue('background-color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`Delete button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Delete button color matched as expected'); + } + }, + + //Save button text + { + description: 'Validate Save button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalop')).getAttribute('value'); + if (elementText !== 'Save') { + throw new Error(`Expected: "Save" button text; Actual: "${elementText}"`); + } + console.log('Passed: Save button text matched as expected'); + } + }, + + //Save button color -green + { + description: 'Validate Save button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalop')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Save button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Save button color matched as expected'); + } + }, + + //Close button text + { + description: 'Validate Close button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalclose')).getText(); + if (elementText !== 'Close') { + throw new Error(`Expected: "Close" button text; Actual: "${elementText}"`); + } + console.log('Passed: Close button text matched as expected'); + } + }, + + //Close button color -white + { + description: 'Validate Close button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalclose')).getCssValue('background-color'); + if (elementStyle !== 'rgba(0, 0, 0, 0)') { + throw new Error(`Close button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Close button color matched as expected'); + } + }, + + //NEXT ACTION - Close DIV + { description: 'Click Close button', action: async () => await driver.findElement(By.css('#modalclose')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again file icon + { description: 'Click Juan Testing Again & Again file icon', action: async () => await driver.findElement(By.css('.doc:nth-child(2) > .fa')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //Juan Testing Again & Again Upload icon is present + { + description: 'Verify Juan Testing Again & Again Upload icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(2) > .float-right .fa-cloud-upload')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Juan Testing Again & Again Upload icon is not present'); + } + console.log('Passed: Juan Testing Again & Again Upload icon is present'); + } + }, + + //Juan Testing Again & Again View icon is present + { + description: 'Verify Juan Testing Again & Again View icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(2) > .float-right > .frame-name > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Juan Testing Again & Again View icon is not present'); + } + console.log('Passed: Juan Testing Again & Again View icon is present'); + } + }, + + //Juan Testing Again & Again Download icon is present + { + description: 'Verify Juan Testing Again & Again Download icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(2) > .float-right .fa-download')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Juan Testing Again & Again Download icon is not present'); + } + console.log('Passed: Juan Testing Again & Again Download icon is present'); + } + }, + + //Juan Testing Again & Again Info icon is present + { + description: 'Verify Juan Testing Again & Again Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(2) > .float-right .fa-info-circle')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Juan Testing Again & Again Info icon is not present'); + } + console.log('Passed: Juan Testing Again & Again Info icon is present'); + } + }, + + //Juan Testing Again & Again Edit icon 2 is present + { + description: 'Verify Juan Testing Again & Again Edit icon 2 is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.list-group-item:nth-child(2) > .float-right .fa-pencil-square-o')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Juan Testing Again & Again Edit icon 2 is not present'); + } + console.log('Passed: Juan Testing Again & Again Edit icon 2 is present'); + } + }, + + //NEXT ACTION - Click Juan Testing Again & Again upload icon + { description: 'Click Juan Testing Again & Again upload icon', action: async () => await driver.findElement(By.css('.list-group-item:nth-child(2) > .float-right .fa-cloud-upload')).click() }, + + //Publish Framework DIV + { + description: 'Wait for DIV to open', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.modal-lg .modal-title')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Publish Framework DIV did not open'); + } + console.log('Passed: Publish Framework DIV opened'); + } + }, + + //Publish Framework DIV title + { + description: 'Validate Publish Framework DIV title', + action: async () => { + const elementText = await driver.findElement(By.css('.modal-lg .modal-title')).getText(); + if (elementText !== 'Publish Framework') { + throw new Error(`Expected: "Publish Framework" DIV title text; Actual: "${elementText}"`); + } + console.log('Passed: Publish Framework DIV title text matched as expected'); + } + }, + + //X icon DIV color -red + { + description: 'Validate X icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-lg .modal-header span')).getCssValue('color'); + if (elementStyle !== 'rgba(246, 60, 40, 1)') { + throw new Error(`DIV "X" icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV X icon color matched as expected'); + } + }, + + //Framework label + { + description: 'Validate Framework label', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype > .form-label')).getText(); + if (elementText !== 'Framework') { + throw new Error(`Expected: "Framework" label text; Actual: "${elementText}"`); + } + console.log('Passed: Framework label text matched as expected'); + } + }, + + //Framework textbox + { + description: 'Validate Framework textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#org')).getAttribute('value'); + if (elementValue !== '873575832') { + throw new Error(`Expected: Framework textbox, "Juan Testing Again & Again" value; Actual: "${elementValue}"`); + } + console.log('Passed: Framework textbox, Juan Testing Again & Again value matched as expected'); + } + }, + + //Display Title label + { + description: 'Validate Display Title label', + action: async () => { + const elementText = await driver.findElement(By.css('#divname > .form-label')).getText(); + if (elementText !== 'Display Title') { + throw new Error(`Expected: "Display Title" label text; Actual: "${elementText}"`); + } + console.log('Passed: Display Title label text matched as expected'); + } + }, + + //Display Title Info icon is present + { + description: 'Verify Display Title Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divname .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Display Title Info icon is not present'); + } + console.log('Passed: Display Title Info icon is present'); + } + }, + + //Display Title textbox + { + description: 'Validate Display Title textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#title')).getAttribute('value'); + if (elementValue !== '') { + throw new Error(`Expected: "Blank" Display Title textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Blank Display Title textbo value matched as expected'); + } + }, + + //Version label + { + description: 'Validate Version label', + action: async () => { + const elementText = await driver.findElement(By.css('#divsource > .form-label')).getText(); + if (elementText !== 'Version') { + throw new Error(`Expected: "Version" label text; Actual: "${elementText}"`); + } + console.log('Passed: Version label text matched as expected'); + } + }, + + //Version Info icon is present + { + description: 'Verify Version Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divsource .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Version Info icon is not present'); + } + console.log('Passed: Version Info icon is present'); + } + }, + + //Version textbox + { + description: 'Validate Version Title textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#version')).getAttribute('value'); + if (elementValue !== '') { + throw new Error(`Expected: "Blank" Version Title textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Blank Version Title textbox value matched as expected'); + } + }, + + //Display Status label + { + description: 'Validate Display Status label', + action: async () => { + const elementText = await driver.findElement(By.css('#divpublisher > .form-label')).getText(); + if (elementText !== 'Display Status') { + throw new Error(`Expected: "Display Status" label text; Actual: "${elementText}"`); + } + console.log('Passed: Display Status label text matched as expected'); + } + }, + + //Display Status Info icon is present + { + description: 'Verify Display Status Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divpublisher .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Display Status Info icon is not present'); + } + console.log('Passed: Display Status Info icon is present'); + } + }, + + //Display Status textbox + { + description: 'Validate Display Status textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#status')).getAttribute('value'); + if (elementValue !== 'Implemented') { + throw new Error(`Expected: Display Status textbox, "Implemented" value; Actual: "${elementValue}"`); + } + console.log('Passed: Display Status textbox, Implemented value matched as expected'); + } + }, + + //Group label + { + description: 'Validate Group label', + action: async () => { + const elementText = await driver.findElement(By.css('#divparent > .form-label')).getText(); + if (elementText !== 'Group') { + throw new Error(`Expected: "Group" label text; Actual: "${elementText}"`); + } + console.log('Passed: Group label text matched as expected'); + } + }, + + //Group Info icon is present + { + description: 'Verify Group Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divparent .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Group Info icon is not present'); + } + console.log('Passed: Group Info icon is present'); + } + }, + + //Group textbox + { + description: 'Validate Group textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#group')).getAttribute('value'); + if (elementValue !== '7') { + throw new Error(`Expected: Group textbox, "Initial Framework Group for Testing" value; Actual: "${elementValue}"`); + } + console.log('Passed: Group textbox, Initial Framework Group for Testing value matched as expected'); + } + }, + + //Download Formats label + { + description: 'Validate Download Formats label', + action: async () => { + const elementText = await driver.findElement(By.css('#divcreator > .form-label')).getText(); + if (elementText !== 'Download Formats') { + throw new Error(`Expected: "Download Formats" label text; Actual: "${elementText}"`); + } + console.log('Passed: Download Formats label text matched as expected'); + } + }, + + //Download Formats Info icon is present + { + description: 'Verify Download Formats Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divcreator .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Download Formats Info icon is not present'); + } + console.log('Passed: Download Formats Info icon is present'); + } + }, + + //CSV checkbox -active + { + description: 'Validate CSV checkbox option enabled', + action: async () => { + const elementStyle = await driver.findElement(By.css('#formatcsv')).getAttribute('checked'); + if (elementStyle !== 'true') { + throw new Error(`CSV checkbox option value checked did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: CSV checkbox option value matched as expected'); + } + }, + + //CSV label + { + description: 'Validate CSV label', + action: async () => { + const elementText = await driver.findElement(By.css('#divcreator > .form-check:nth-child(4) > .form-check-label')).getText(); + if (elementText !== 'CSV') { + throw new Error(`Expected: "CSV" label text; Actual: "${elementText}"`); + } + console.log('Passed: CSV label text matched as expected'); + } + }, + + //PDF checkbox -active + { + description: 'Validate PDF checkbox option enabled', + action: async () => { + const elementStyle = await driver.findElement(By.css('#formatpdf')).getAttribute('checked'); + if (elementStyle !== 'true') { + throw new Error(`PDF checkbox option value checked did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: PDF checkbox option value matched as expected'); + } + }, + + //PDF label + { + description: 'Validate PDF label', + action: async () => { + const elementText = await driver.findElement(By.css('.form-check:nth-child(5) > .form-check-label')).getText(); + if (elementText !== 'PDF') { + throw new Error(`Expected: "PDF" label text; Actual: "${elementText}"`); + } + console.log('Passed: PDF label text matched as expected'); + } + }, + + //CASE JSON/API* checkbox -active + { + description: 'Validate CASE JSON API checkbox option enabled', + action: async () => { + const elementStyle = await driver.findElement(By.css('#formatcase')).getAttribute('checked'); + if (elementStyle !== 'true') { + throw new Error(`CASE JSON/API* checkbox option value checked did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: CASE JSON/API* checkbox option value matched as expected'); + } + }, + + //CASE JSON/API* label + { + description: 'Validate CASE JSON API label', + action: async () => { + const elementText = await driver.findElement(By.css('.form-check:nth-child(6) > .form-check-label')).getText(); + if (elementText !== 'CASE JSON/API*') { + throw new Error(`Expected: "CASE JSON/API*" label text; Actual: "${elementText}"`); + } + console.log('Passed: CASE JSON/API* label text matched as expected'); + } + }, + + //Asterisk icons + { + description: 'Validate Asterisk icons', + action: async () => { + const elementText = await driver.findElement(By.css('#divcreator')).getText(); + if (elementText !== 'This option also allows access to this framework via CASE compliant API') { + throw new Error(`Expected: "This option also allows access to this framework via CASE compliant API" label text; Actual: "${elementText}"`); + } + console.log('Passed: This option also allows access to this framework via CASE compliant API label text matched as expected'); + } + }, + + //Asterisk label + { + description: 'Validate Asterisk label', + action: async () => { + const elementText = await driver.findElement(By.css('small')).getText(); + if (elementText !== 'This option also allows access to this framework via CASE compliant API') { + throw new Error(`Expected: "This option also allows access to this framework via CASE compliant API" label text; Actual: "${elementText}"`); + } + console.log('Passed: This option also allows access to this framework via CASE compliant API label text matched as expected'); + } + }, + + //Comment Settings label + { + description: 'Validate Comment Settings label', + action: async () => { + const elementText = await driver.findElement(By.css('#divstatus > .form-label')).getText(); + if (elementText !== 'Comment Settings') { + throw new Error(`Expected: "Comment Settings" label text; Actual: "${elementText}"`); + } + console.log('Passed: Comment Settings label text matched as expected'); + } + }, + + //Allow Comments checkbox -active + { + description: 'Validate Allow Comments checkbox option enabled', + action: async () => { + const elementStyle = await driver.findElement(By.css('#comments')).getAttribute('checked'); + if (elementStyle !== 'true') { + throw new Error(`Allow Comments checkbox option value checked did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Allow Comments checkbox option value matched as expected'); + } + }, + + //Allow Comments label + { + description: 'Validate Allow Comments label', + action: async () => { + const elementText = await driver.findElement(By.css('.form-check:nth-child(3) > .form-check-label')).getText(); + if (elementText !== 'Allow Comments') { + throw new Error(`Expected: "Allow Comments" label text; Actual: "${elementText}"`); + } + console.log('Passed: Allow Comments label text matched as expected'); + } + }, + + //Comments are private checkbox + { + description: 'Verify Comments are private checkbox is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#private')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Comments are private checkbox not found'); + } + console.log('Passed: Comments are private checkbox present'); + } + }, + + //Comments are private label + { + description: 'Validate Comments are private label', + action: async () => { + const elementText = await driver.findElement(By.css('#divstatus > .form-check:nth-child(4) > .form-check-label')).getText(); + if (elementText !== 'Comments are private') { + throw new Error(`Expected: "Comments are private" label text; Actual: "${elementText}"`); + } + console.log('Passed: Comments are private label text matched as expected'); + } + }, + + //Publisher's Notes label + { + description: 'Validate Publishers Notes label', + action: async () => { + const elementText = await driver.findElement(By.css('#divpubnotes > .form-label')).getText(); + if (elementText !== `Publisher's Notes`) { + throw new Error(`Expected: "Publisher's Notes" label text; Actual: "${elementText}"`); + } + console.log(`Passed: Publisher's Notes label text matched as expected`); + } + }, + + //Publisher's Notes textbox + { + description: 'Validate Publishers Notes textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#pubnotes')).getAttribute('value'); + if (elementValue !== '') { + throw new Error(`Expected: "Blank" Publisher's Notes textbox value; Actual: "${elementValue}"`); + } + console.log(`Passed: Blank Publisher's Notes textbox value matched as expected`); + } + }, + + //Publish button text + { + description: 'Validate Publish button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalop')).getAttribute('value'); + if (elementText !== 'Publish') { + throw new Error(`Expected: "Publish" button text; Actual: "${elementText}"`); + } + console.log('Passed: Publish button text matched as expected'); + } + }, + + //Publish button color -green + { + description: 'Validate Publish button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalop')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Publish button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: SPublish button color matched as expected'); + } + }, + + //Close button text + { + description: 'Validate Close button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalclose')).getText(); + if (elementText !== 'Close') { + throw new Error(`Expected: "Close" button text; Actual: "${elementText}"`); + } + console.log('Passed: Close button text matched as expected'); + } + }, + + //Close button color -white + { + description: 'Validate Close button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalclose')).getCssValue('background-color'); + if (elementStyle !== 'rgba(0, 0, 0, 0)') { + throw new Error(`Close button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Close button color matched as expected'); + } + }, + + //NEXT ACTION - Publish Framework -validation + { description: 'Click Publish button', action: async () => await driver.findElement(By.css('#modalop')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //Display Title valiation text + { + description: 'Display Title validattion text', + action: async () => { + const elementText = await driver.findElement(By.css('#divname > .invalid-feedback')).getText(); + if (elementText !== 'You must enter a framework title') { + throw new Error(`Expected: "You must enter a framework title" Display Title validation text; Actual: "${elementText}"`); + } + console.log('Passed: Display Title validation text matched as expected'); + } + }, + + //Display Title validation text color -red + { + description: 'Validate text color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#divname > .invalid-feedback')).getCssValue('color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`Display Title validation text color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Display Title validation text color matched as expected'); + } + }, + + //Version valiation text + { + description: 'Version validattion text', + action: async () => { + const elementText = await driver.findElement(By.css('#divsource > .invalid-feedback')).getText(); + if (elementText !== 'You must enter a version for the published framework') { + throw new Error(`Expected: "You must enter a version for the published framework" Version validation text; Actual: "${elementText}"`); + } + console.log('Passed: Version validation text matched as expected'); + } + }, + + //Version validation text color -red + { + description: 'Validate text color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#divsource > .invalid-feedback')).getCssValue('color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`Version validation text color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Version validation text color matched as expected'); + } + }, + + //DIV valiation text + { + description: 'DIV validattion text', + action: async () => { + const elementText = await driver.findElement(By.css('b')).getText(); + if (elementText !== 'Please enter a value for all highlighted fields') { + throw new Error(`Expected: "Please enter a value for all highlighted fields" DIV validation text; Actual: "${elementText}"`); + } + console.log('Passed: DIV validation text matched as expected'); + } + }, + + //DIV validation text color -red + { + description: 'Validate text color', + action: async () => { + const elementStyle = await driver.findElement(By.css('b')).getCssValue('color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`DIV validation text color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV validation text color matched as expected'); + } + }, + + //NEXT ACTION - Close DIV + { description: 'Click Close button', action: async () => await driver.findElement(By.css('#modalclose')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again file icon + { description: 'Click Juan Testing Again & Again file icon', action: async () => await driver.findElement(By.css('.doc:nth-child(2) > .fa')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again View Icon + { description: 'Click View icon', action: async () => await driver.findElement(By.css('.list-group-item:nth-child(2) > .float-right > .frame-name > .fa')).click() }, + + //Wait for page to load - Correlation Coverages View Details button + { + description: 'Wait for page to load', + action: async () => { + return await driver.wait(until.elementLocated(By.css('h2')), 10000).catch(() => false); + } + }, + + //Juan Testing Again & Again page title + { + description: 'Validate Juan Testing Again & Again page title', + action: async () => { + const elementText = await driver.findElement(By.css('h2')).getText(); + if (elementText !== 'Juan Testing Again & Again') { + throw new Error(`Expected: "Juan Testing Again & Again" page title; Actual: "${elementText}"`); + } + console.log('Passed: Juan Testing Again & Again page title matched as expected'); + } + }, + + //Framework Management page title text color -dark blue + { + description: 'Validate Framework Management page title text color', + action: async () => { + const elementStyle = await driver.findElement(By.css('h2')).getCssValue('color'); + if (elementStyle !== 'rgba(40, 39, 90, 1)') { + throw new Error(`Framework Management page title text color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Framework Management page title text color matched as expected'); + } + }, + + //Framework Management page title text font + { + description: 'Validate Framework Management page title text font size', + action: async () => { + const elementStyle = await driver.findElement(By.css('h2')).getCssValue('font-size'); + if (elementStyle !== '32px') { + throw new Error(`Framework Management page title text font-size did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Framework Management page title text font-size matched as expected'); + } + }, + + //Edit icon + { + description: 'Verify Edit icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.fa-pencil-square-o')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Edit icon not found'); + } + console.log('Passed: Edit icon present'); + } + }, + + //Publish button icon + { + description: 'Verify Publish button icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.fa-pencil-square-o')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Publish button icon not found'); + } + console.log('Passed: Publish button icon present'); + } + }, + + //Publish button text + { + description: 'Validate Publish button text', + action: async () => { + const elementText = await driver.findElement(By.linkText('Publish')).getText(); + if (elementText !== 'Publish') { + throw new Error(`Expected: "Publish" button text; Actual: "${elementText}"`); + } + console.log('Passed: Publish button text matched as expected'); + } + }, + + //Publish button color -green + { + description: 'Validate Publish button color', + action: async () => { + const elementStyle = await driver.findElement(By.linkText('Publish')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Publish button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Publish button color matched as expected'); + } + }, + + //Download button icon + { + description: 'Verify Download button icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.fa-download')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Download button icon not found'); + } + console.log('Passed: Download button icon present'); + } + }, + + //Download button text + { + description: 'Validate Download button text', + action: async () => { + const elementText = await driver.findElement(By.linkText('Download')).getText(); + if (elementText !== 'Download') { + throw new Error(`Expected: "Download" button text; Actual: "${elementText}"`); + } + console.log('Passed: Download button text matched as expected'); + } + }, + + //Download button color -green + { + description: 'Validate Download button color', + action: async () => { + const elementStyle = await driver.findElement(By.linkText('Download')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Download button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Download button color matched as expected'); + } + }, + + //Add New Item button icon + { + description: 'Verify Add New Item button icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.btn > .fa-plus')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Add New Item button icon not found'); + } + console.log('Passed: Add New Item button icon present'); + } + }, + + //Add New Item button text + { + description: 'Validate Add New Item button text', + action: async () => { + const elementText = await driver.findElement(By.linkText('Add New Item')).getText(); + if (elementText !== 'Add New Item') { + throw new Error(`Expected: "Add New Item" button text; Actual: "${elementText}"`); + } + console.log('Passed: Add New Item button text matched as expected'); + } + }, + + //Add New Item button color -green + { + description: 'Validate Add New Item button color', + action: async () => { + const elementStyle = await driver.findElement(By.linkText('Add New Item')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Add New Item button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Add New Item button color matched as expected'); + } + }, + + //Add New Item button text + { + description: 'Validate Add New Item button text', + action: async () => { + const elementText = await driver.findElement(By.linkText('Add New Item')).getText(); + if (elementText !== 'Add New Item') { + throw new Error(`Expected: "Add New Item" button text; Actual: "${elementText}"`); + } + console.log('Passed: Add New Item button text matched as expected'); + } + }, + + //Add New Item button color -green + { + description: 'Validate Add New Item button color', + action: async () => { + const elementStyle = await driver.findElement(By.linkText('Add New Item')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Add New Item button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Add New Item button color matched as expected'); + } + }, + + //Draft button text + { + description: 'Validate Draft button text', + action: async () => { + const elementText = await driver.findElement(By.css('.badge-secondary')).getText(); + if (elementText !== 'Draft') { + throw new Error(`Expected: "Draft" button text; Actual: "${elementText}"`); + } + console.log('Passed: Draft button text matched as expected'); + } + }, + + //Draft button color -gray + { + description: 'Validate Draft button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.badge-secondary')).getCssValue('background-color'); + if (elementStyle !== 'rgba(108, 117, 125, 1)') { + throw new Error(`Draft button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Draft button color matched as expected'); + } + }, + + //Effective date label + { + description: 'Validate Effective date label', + action: async () => { + const elementText = await driver.findElement(By.css('.mr-2 > em')).getText(); + if (elementText !== 'Effective 12/02/2022') { + throw new Error(`Expected: "Effective 12/02/2022" text; Actual: "${elementText}"`); + } + console.log('Passed: Effective 12/02/2022 text matched as expected'); + } + }, + + //Created by label + { + description: 'Validate Created by label', + action: async () => { + const elementText = await driver.findElement(By.css('span:nth-child(7)')).getText(); + if (elementText !== 'Created by: Juancho') { + throw new Error(`Expected: "Created by: Juancho" text; Actual: "${elementText}"`); + } + console.log('Passed: Created by: Juancho text matched as expected'); + } + }, + + //Source label + { + description: 'Validate Source label', + action: async () => { + const elementText = await driver.findElement(By.css('.mt-1')).getText(); + if (elementText !== 'Source: https://www.espn.com') { + throw new Error(`Expected: "Source: https://www.espn.com" text; Actual: "${elementText}"`); + } + console.log('Passed: Source: https://www.espn.com text matched as expected'); + } + }, + + //Source URL label + { + description: 'Validate Source URL label', + action: async () => { + const elementText = await driver.findElement(By.linkText('https://www.espn.com')).getText(); + if (elementText !== 'https://www.espn.com') { + throw new Error(`Expected: Source URL: "https://www.espn.com" link text; Actual: "${elementText}"`); + } + console.log('Passed: Source URL: https://www.espn.com link text matched as expected'); + } + }, + + //Source edit icon + { + description: 'Verify Source edit icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.fa-external-link')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Source edit icon not found'); + } + console.log('Passed: Source edit icon present'); + } + }, + + //Search textbox -placeholder + { + description: 'Validate Search textbox placeholder', + action: async () => { + const elementValue = await driver.findElement(By.css('#framework-item-filter')).getAttribute('placeholder'); + if (elementValue !== 'Search...') { + throw new Error(`Expected: "Search" textbox placeholder; Actual: "${elementValue}"`); + } + console.log('Passed: Search textbox placeholder matched as expected'); + } + }, + + //Clear Search icon + { + description: 'Verify Clear Search icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.fa-times')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Clear Search icon not found'); + } + console.log('Passed: Clear Search icon present'); + } + }, + + //Comments button comment icon + { + description: 'Verify Comments button comment icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.fa-comment')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Comments button comment icon not found'); + } + console.log('Passed: Comments button comment icon present'); + } + }, + + //Comments 25 button text + { + description: 'Validate Comments button text', + action: async () => { + const elementText = await driver.findElement(By.css('.btn-sm:nth-child(1)')).getText(); + if (elementText !== 'Comments 25') { + throw new Error(`Expected: "Comments 25" button text; Actual: "${elementText}"`); + } + console.log('Passed: Comments 25 button text matched as expected'); + } + }, + + //Total comments button icon + { + description: 'Verify Total comments button icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.badge-light')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Total comments button icon not found'); + } + console.log('Passed: Total comments button icon present'); + } + }, + + //Comments button color -green + { + description: 'Validate Comments button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.badge-secondary')).getCssValue('background-color'); + if (elementStyle !== 'rgba(108, 117, 125, 1)') { + throw new Error(`Comments button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Comments button color matched as expected'); + } + }, + + //Expand All button icon + { + description: 'Verify Expand All button icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.fa-expand')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Expand All button icon not found'); + } + console.log('Passed: Expand All button icon present'); + } + }, + + //Expand All button text + { + description: 'Validate Expand All button text', + action: async () => { + const elementText = await driver.findElement(By.css('#expandall')).getText(); + if (elementText !== 'Expand All') { + throw new Error(`Expected: "Expand All" button text; Actual: "${elementText}"`); + } + console.log('Passed: Expand All button text matched as expected'); + } + }, + + //Expand All button color -green + { + description: 'Validate Expand Allbutton color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#expandall')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Expand All button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Expand All button color matched as expected'); + } + }, + + //Collapse All button icon + { + description: 'Verify Collapse All button icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.fa-compress')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Collapse All button icon not found'); + } + console.log('Passed: Collapse All button icon present'); + } + }, + + //Collapse All button text + { + description: 'Validate Collapse All button text', + action: async () => { + const elementText = await driver.findElement(By.css('#collapseall')).getText(); + if (elementText !== 'Collapse All') { + throw new Error(`Expected: "Collapse All" button text; Actual: "${elementText}"`); + } + console.log('Passed: Collapse All button text matched as expected'); + } + }, + + //Collapse All button color -green + { + description: 'Validate Collapse All button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#collapseall')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Collapse All button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Collapse All button color matched as expected'); + } + }, + + //Parent Standard Target icon + { + description: 'Verify Parent Standard Target icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#std-873617672 > .stdtext > .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Parent Standard Target icon not found'); + } + console.log('Passed: Parent Standard Target icon present'); + } + }, + + //Parent Standard text + { + description: 'Validate Parent Standard text', + action: async () => { + const elementText = await driver.findElement(By.css('#std-873617672 .stdstr')).getText(); + if (elementText !== 'Baseball and Statistics') { + throw new Error(`Expected: Parent Standard "Baseball and Statistics" text; Actual: "${elementText}"`); + } + console.log('Passed: Parent Standard text matched as expected'); + } + }, + + //Parent Standard text -grade + { + description: 'Validate Parent Standard grade text', + action: async () => { + const elementText = await driver.findElement(By.css('#std-873617672 em')).getText(); + if (elementText !== '(Grade: 9,10,11,12)') { + throw new Error(`Expected: Parent Standard "(Grade: 9,10,11,12)" text; Actual: "${elementText}"`); + } + console.log('Passed: Parent Standard grade text matched as expected'); + } + }, + + //Parent Standard Comments icon text + { + description: 'Validate Parent Standard Comments icon text', + action: async () => { + const elementText = await driver.findElement(By.css('#std-873617672 .badge')).getText(); + if (elementText !== '14') { + throw new Error(`Expected: Parent Standard Comments icon "14" text; Actual: "${elementText}"`); + } + console.log('Passed: Parent Standard Comments icon text matched as expected'); + } + }, + + //Parent Standard Comments icon color -red + { + description: 'Validate arent Standard Comments icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#std-873617672 .badge')).getCssValue('background-color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`Parent Standard Comments icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Parent Standard Comments icon color matched as expected'); + } + }, + + //Parent Standard Info icon + { + description: 'Verify Parent Standard Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#std-873617672 .fa-info-circle')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Parent Standard Info icon not found'); + } + console.log('Passed: Parent Standard Info icon present'); + } + }, + + //Parent Standard Ellipsis icon + { + description: 'Verify Parent Standard Ellipsis icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#std-873617672 .fa-ellipsis-h')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Parent Standard Ellipsis icon not found'); + } + console.log('Passed: Parent Standard Ellipsis icon present'); + } + }, + + //Parent Standard 2 Expand icon + { + description: 'Verify Parent Standard 2 Expand icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#icon-873617673')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Parent Standard 2 Expand icon not found'); + } + console.log('Passed: Parent Standard 2 Expand icon present'); + } + }, + + //Parent Standard 2 text + { + description: 'Validate Parent Standard 2 text', + action: async () => { + const elementText = await driver.findElement(By.css('#std-873617673 .stdstr')).getText(); + if (elementText !== 'Probabilities LFGSD') { + throw new Error(`Expected: Parent Standard 2 "Probabilities LFGSD" text; Actual: "${elementText}"`); + } + console.log('Passed: Parent Standard 2 text matched as expected'); + } + }, + + //Parent Standard 2 text -grade + { + description: 'Validate Parent Standard 2 gade text', + action: async () => { + const elementText = await driver.findElement(By.css('#std-873617673 em')).getText(); + if (elementText !== '(Grade: 9)') { + throw new Error(`Expected: Parent Standard 2 "(Grade: 9)" text; Actual: "${elementText}"`); + } + console.log('Passed: Parent Standard 2 grade text matched as expected'); + } + }, + + //Parent Standard 2 Comments icon text + { + description: 'Validate Parent Standard 2 Comments icon text', + action: async () => { + const elementText = await driver.findElement(By.css('#std-873617673 .badge')).getText(); + if (elementText !== '11') { + throw new Error(`Expected: Parent Standard 2 Comments icon "11" text; Actual: "${elementText}"`); + } + console.log('Passed: Parent Standard 2 Comments icon text matched as expected'); + } + }, + + //Parent Standard 2 Comments icon color -red + { + description: 'Validate arent Standard 2 Comments icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#std-873617673 .badge')).getCssValue('background-color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`Parent Standard 2 Comments icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Parent Standard 2 Comments icon color matched as expected'); + } + }, + + //Parent Standard 2 Info icon + { + description: 'Verify Parent Standard 2 Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#std-873617673 .fa-info-circle')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Parent Standard 2 Info icon not found'); + } + console.log('Passed: Parent Standard 2 Info icon present'); + } + }, + + //Parent Standard 2 Ellipsis icon + { + description: 'Verify Parent Standard 2 Ellipsis icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#std-873617673 .fa-ellipsis-h')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Parent Standard 2 Ellipsis icon not found'); + } + console.log('Passed: Parent Standard 2 Ellipsis icon present'); + } + }, + + //NEXT ACTION - Navigate to Framework Management page + { description: 'Click Frameworks navigation link', action: async () => await driver.findElement(By.linkText('Frameworks')).click() }, + + //Wait for page to load - Correlation Coverages View Details button + { + description: 'Wait for page to load', + action: async () => { + return await driver.wait(until.elementLocated(By.css('h2')), 10000).catch(() => false); + } + }, + + //NEXT ACTION - Click My Latest Organization For Now link + { description: 'Click My Latest Organization For Now link', action: async () => await driver.findElement(By.linkText('My Latest Organization For Now')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again file icon + { description: 'Click Juan Testing Again & Again file icon', action: async () => await driver.findElement(By.css('.doc:nth-child(2) > .fa')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again Download Icon + { description: 'Click Download icon', action: async () => await driver.findElement(By.css('.list-group-item:nth-child(2) > .float-right .fa-download')).click() }, + + //Export Framework DIV + { + description: 'Wait for DIV to open', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.modal-lg .modal-title')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Export Framework DIV did not open'); + } + console.log('Passed: Export Framework DIV opened'); + } + }, + + //Export Framework DIV title + { + description: 'Validate Export Framework DIV title', + action: async () => { + const elementText = await driver.findElement(By.css('.modal-lg .modal-title')).getText(); + if (elementText !== 'Export Framework') { + throw new Error(`Expected: "Export Framework" DIV title text; Actual: "${elementText}"`); + } + console.log('Passed: Export Framework DIV title text matched as expected'); + } + }, + + //X icon DIV color -red + { + description: 'Validate X icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-lg .modal-header span')).getCssValue('color'); + if (elementStyle !== 'rgba(246, 60, 40, 1)') { + throw new Error(`DIV "X" icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV X icon color matched as expected'); + } + }, + + //Juan Testing Again & Again title + { + description: 'Validate Juan Testing Again & Again title', + action: async () => { + const elementText = await driver.findElement(By.css('b')).getText(); + if (elementText !== 'Juan Testing Again & Again') { + throw new Error(`Expected: "Juan Testing Again & Again" title text; Actual: "${elementText}"`); + } + console.log('Passed: Juan Testing Again & Again title text matched as expected'); + } + }, + + //Please choose format text + { + description: 'Validate Please choose format text', + action: async () => { + const elementText = await driver.findElement(By.css('p:nth-child(2)')).getText(); + if (elementText !== 'Please choose which format you wish to download:') { + throw new Error(`Expected: "Please choose which format you wish to download:" text; Actual: "${elementText}"`); + } + console.log('Passed: Please choose which format you wish to download: text matched as expected'); + } + }, + + //Export CSV button text + { + description: 'Validate Export CSV button text', + action: async () => { + const elementText = await driver.findElement(By.linkText('Export CSV')).getText(); + if (elementText !== 'Export CSV') { + throw new Error(`Expected: "Export CSV" button text; Actual: "${elementText}"`); + } + console.log('Passed: Export CSV button text matched as expected'); + } + }, + + //Export CSV button color -green + { + description: 'Validate Export CSV button color', + action: async () => { + const elementStyle = await driver.findElement(By.linkText('Export CSV')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Export CSV button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Export CSV button color matched as expected'); + } + }, + + //Export CASE JSON button text + { + description: 'Validate Export CASE JSON button text', + action: async () => { + const elementText = await driver.findElement(By.linkText('Export CASE JSON')).getText(); + if (elementText !== 'Export CASE JSON') { + throw new Error(`Expected: "Export CASE JSON" button text; Actual: "${elementText}"`); + } + console.log('Passed: Export CASE JSON button text matched as expected'); + } + }, + + //CASE JSON button color -green + { + description: 'Validate Export CASE JSON button color', + action: async () => { + const elementStyle = await driver.findElement(By.linkText('Export CASE JSON')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Export CASE JSON button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Export CASE JSON button color matched as expected'); + } + }, + + //Close button text + { + description: 'Validate Close button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalclose')).getText(); + if (elementText !== 'Close') { + throw new Error(`Expected: "Close" button text; Actual: "${elementText}"`); + } + console.log('Passed: Close button text matched as expected'); + } + }, + + //Close button color -white + { + description: 'Validate Close button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalclose')).getCssValue('background-color'); + if (elementStyle !== 'rgba(0, 0, 0, 0)') { + throw new Error(`Close button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Close button color matched as expected'); + } + }, + + //NEXT ACTION - Close DIV + { description: 'Click Close button', action: async () => await driver.findElement(By.css('#modalclose')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again file icon + { description: 'Click Juan Testing Again & Again file icon', action: async () => await driver.findElement(By.css('.doc:nth-child(2) > .fa')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again Info Icon + { description: 'Click Info icon', action: async () => await driver.findElement(By.css('.list-group-item:nth-child(2) > .float-right .fa-info-circle')).click() }, + + //View Framework DIV + { + description: 'Wait for DIV to open', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.modal-lg .modal-title')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('View Framework DIV did not open'); + } + console.log('Passed: View Framework DIV opened'); + } + }, + + //View Framework Info DIV title + { + description: 'Validate View Framework Info DIV title', + action: async () => { + const elementText = await driver.findElement(By.css('.modal-lg .modal-title')).getText(); + if (elementText !== 'View Framework Info') { + throw new Error(`Expected: "View Framework Info" DIV title text; Actual: "${elementText}"`); + } + console.log('Passed: View Framework Info DIV title text matched as expected'); + } + }, + + //X icon DIV color -red + { + description: 'Validate X icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-lg .modal-header span')).getCssValue('color'); + if (elementStyle !== 'rgba(246, 60, 40, 1)') { + throw new Error(`DIV "X" icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV X icon color matched as expected'); + } + }, + + //Type label + { + description: 'Validate Type label', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype > .form-label')).getText(); + if (elementText !== 'Type') { + throw new Error(`Expected: "Type" label; Actual: "${elementText}"`); + } + console.log('Passed: Type label matched as expected'); + } + }, + + //Type description + { + description: 'Validate Type description', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype')).getText(); + if (elementText !== 'Framework') { + throw new Error(`Expected: "Framework" type description text; Actual: "${elementText}"`); + } + console.log('Passed: Framework type description text matched as expected'); + } + }, + + //Name label + { + description: 'Validate Name label', + action: async () => { + const elementText = await driver.findElement(By.css('#divname > .form-label')).getText(); + if (elementText !== 'Name') { + throw new Error(`Expected: "Name" label; Actual: "${elementText}"`); + } + console.log('Passed: Name label matched as expected'); + } + }, + + //Name description + { + description: 'Validate Name description', + action: async () => { + const elementText = await driver.findElement(By.css('#divname')).getText(); + if (elementText !== 'Juan Testing Again & Again') { + throw new Error(`Expected: "Juan Testing Again & Again" name description text; Actual: "${elementText}"`); + } + console.log('Passed: Juan Testing Again & Again name description text matched as expected'); + } + }, + + //Source URL label + { + description: 'Validate Source URL label', + action: async () => { + const elementText = await driver.findElement(By.css('.form-row:nth-child(1) > #divsource > .form-label')).getText(); + if (elementText !== 'Source URL') { + throw new Error(`Expected: "Source URL" label; Actual: "${elementText}"`); + } + console.log('Passed: Source URL label matched as expected'); + } + }, + + //Source URL description + { + description: 'Validate Source URL description', + action: async () => { + const elementText = await driver.findElement(By.linkText('https://www.espn.com')).getText(); + if (elementText !== 'https://www.espn.com') { + throw new Error(`Expected: "https://www.espn.com" source URL description text; Actual: "${elementText}"`); + } + console.log('Passed: https://www.espn.com source URL description text matched as expected'); + } + }, + + //Parent label + { + description: 'Validate Parent label', + action: async () => { + const elementText = await driver.findElement(By.css('.form-row:nth-child(1) > #divparent > .form-label')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "Parent" label; Actual: "${elementText}"`); + } + console.log('Passed: Parent label matched as expected'); + } + }, + + //Parent description + { + description: 'Validate Parent description', + action: async () => { + const elementText = await driver.findElement(By.css('.form-row:nth-child(1) > #divparent')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "Parent" parent description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent parent description text matched as expected'); + } + }, + + //Description label + { + description: 'Validate Description label', + action: async () => { + const elementText = await driver.findElement(By.css('#divdescription > .form-label')).getText(); + if (elementText !== 'Description') { + throw new Error(`Expected: "Description" label; Actual: "${elementText}"`); + } + console.log('Passed: Description label matched as expected'); + } + }, + + //Description description + { + description: 'Validate Description description', + action: async () => { + const elementText = await driver.findElement(By.css('#divdescription')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "1" parent description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent parent description text matched as expected'); + } + }, + + //Creator label + { + description: 'Validate Creator label', + action: async () => { + const elementText = await driver.findElement(By.css('#divcreator > .form-label')).getText(); + if (elementText !== 'Creator') { + throw new Error(`Expected: "Creator" label; Actual: "${elementText}"`); + } + console.log('Passed: Creator label matched as expected'); + } + }, + + //Creator description + { + description: 'Validate Creator description', + action: async () => { + const elementText = await driver.findElement(By.css('#divcreator')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "2" creator description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent creator description text matched as expected'); + } + }, + + //Publisher label + { + description: 'Validate Publisher label', + action: async () => { + const elementText = await driver.findElement(By.css('#divpublisher > .form-label')).getText(); + if (elementText !== 'Publisher') { + throw new Error(`Expected: "Publisher" label; Actual: "${elementText}"`); + } + console.log('Passed: Publisher label matched as expected'); + } + }, + + //Publisher description + { + description: 'Validate Publisher description', + action: async () => { + const elementText = await driver.findElement(By.css('#divpublisher')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "3" publisher description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent publisher description text matched as expected'); + } + }, + + //Status label + { + description: 'Validate Status label', + action: async () => { + const elementText = await driver.findElement(By.css('#divstatus > .form-label')).getText(); + if (elementText !== 'Status') { + throw new Error(`Expected: "Status" label; Actual: "${elementText}"`); + } + console.log('Passed: Status label matched as expected'); + } + }, + + //Status description + { + description: 'Validate Status description', + action: async () => { + const elementText = await driver.findElement(By.css('#divstatus')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "4" Status description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent Status description text matched as expected'); + } + }, + + //Effective Date label + { + description: 'Validate Effective Date label', + action: async () => { + const elementText = await driver.findElement(By.css('#diveffective > .form-label')).getText(); + if (elementText !== 'Effective Date') { + throw new Error(`Expected: "Effective Date" label; Actual: "${elementText}"`); + } + console.log('Passed: Effective Date label matched as expected'); + } + }, + + //Effective Date description + { + description: 'Validate Effective Date description', + action: async () => { + const elementText = await driver.findElement(By.css('#diveffective')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "5" effective date description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent effective date description text matched as expected'); + } + }, + + //Language label + { + description: 'Validate Language label', + action: async () => { + const elementText = await driver.findElement(By.css('#divlang > .form-label')).getText(); + if (elementText !== 'Language') { + throw new Error(`Expected: "Language" label; Actual: "${elementText}"`); + } + console.log('Passed: Language label matched as expected'); + } + }, + + //Language description + { + description: 'Validate Language description', + action: async () => { + const elementText = await driver.findElement(By.css('#divlang')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "5" language description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent language description text matched as expected'); + } + }, + + //Version label + { + description: 'Validate Version label', + action: async () => { + const elementText = await driver.findElement(By.css('#divversion > .form-label')).getText(); + if (elementText !== 'Version') { + throw new Error(`Expected: "Version" label; Actual: "${elementText}"`); + } + console.log('Passed:Version label matched as expected'); + } + }, + + //Version description + { + description: 'Validate Version description', + action: async () => { + const elementText = await driver.findElement(By.css('#divversion')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "6" version description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent version description text matched as expected'); + } + }, + + //Notes label + { + description: 'Validate Notes label', + action: async () => { + const elementText = await driver.findElement(By.css('#divnotes > .form-label')).getText(); + if (elementText !== 'Notes') { + throw new Error(`Expected: "Notes" label; Actual: "${elementText}"`); + } + console.log('Passed: Notes label matched as expected'); + } + }, + + //Notes description + { + description: 'Validate Notes description', + action: async () => { + const elementText = await driver.findElement(By.css('#divnotes')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "6" notes description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent notes description text matched as expected'); + } + }, + + //Created label + { + description: 'Validate Created label', + action: async () => { + const elementText = await driver.findElement(By.css('.form-row:nth-child(4) > #divsource > .form-label')).getText(); + if (elementText !== 'Created') { + throw new Error(`Expected: "Created" label; Actual: "${elementText}"`); + } + console.log('Passed: Created label matched as expected'); + } + }, + + //Created description + { + description: 'Validate Created description', + action: async () => { + const elementText = await driver.findElement(By.css('.form-row:nth-child(4) > #divsource')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "7" created description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent created description text matched as expected'); + } + }, + + //Last Modified label + { + description: 'Validate Last Modified label', + action: async () => { + const elementText = await driver.findElement(By.css('.form-row:nth-child(4) > #divparent > .form-label')).getText(); + if (elementText !== 'Last Modified') { + throw new Error(`Expected: "Last Modified" label; Actual: "${elementText}"`); + } + console.log('Passed: Last Modified label matched as expected'); + } + }, + + //Last Modified description + { + description: 'Validate Last Modified description', + action: async () => { + const elementText = await driver.findElement(By.css('.form-row:nth-child(4) > #divparent')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "8" last modified description text; Actual: "${elementText}"`); + } + console.log('Passed: Parent last modified description text matched as expected'); + } + }, + + //NEXT ACTION - Close DIV + { description: 'Click Close button', action: async () => await driver.findElement(By.css('#modalclose')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again file icon + { description: 'Click Juan Testing Again & Again file icon', action: async () => await driver.findElement(By.css('.doc:nth-child(2) > .fa')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, + + //NEXT ACTION - Click Juan Testing Again & Again Edit Icon + { description: 'Click Edit icon', action: async () => await driver.findElement(By.css('.list-group-item:nth-child(2) > .float-right .fa-pencil-square-o')).click() }, + + //Edit Framework DIV + { + description: 'Wait for Edit Framework DIV to open', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.modal-lg .modal-title')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Edit Framework DIV did not open'); + } + console.log('Passed: Edit Framework DIV opened'); + } + }, + + //Edit Framework title + { + description: 'Validate Edit Framework DIV title', + action: async () => { + const elementText = await driver.findElement(By.css('.modal-lg .modal-title')).getText(); + if (elementText !== 'Edit Framework') { + throw new Error(`Expected: "Edit Framework" DIV title text; Actual: "${elementText}"`); + } + console.log('Passed: Edit Framework DIV title text matched as expected'); + } + }, + + //X icon DIV color -red + { + description: 'Validate X icon color', + action: async () => { + const elementStyle = await driver.findElement(By.css('.modal-lg .modal-header span')).getCssValue('color'); + if (elementStyle !== 'rgba(246, 60, 40, 1)') { + throw new Error(`DIV "X" icon color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: DIV X icon color matched as expected'); + } + }, + + //Type label + { + description: 'Validate Type label', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype > .form-label')).getText(); + if (elementText !== 'Type') { + throw new Error(`Expected: "Type" label text; Actual: "${elementText}"`); + } + console.log('Passed: Type label text matched as expected'); + } + }, + + //Type Info icon is present + { + description: 'Verify Type Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divtype .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Type Info icon is not present'); + } + console.log('Passed: Type Info icon is present'); + } + }, + + //Type value text + { + description: 'Validate Type value text', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype')).getText(); + if (elementText !== 'Framework') { + throw new Error(`Expected: "Framework" Type value text; Actual: "${elementText}"`); + } + console.log('Passed: "Framework" Type value text matched as expected'); + } + }, + + //Name label + { + description: 'Validate Type label', + action: async () => { + const elementText = await driver.findElement(By.css('#divtype > .form-label')).getText(); + if (elementText !== 'Type') { + throw new Error(`Expected: "Type" labele text; Actual: "${elementText}"`); + } + console.log('Passed: Type labele text matched as expected'); + } + }, + + //Name textbox + { + description: 'Validate Name textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#orgname')).getText(); + if (elementValue !== '') { + throw new Error(`Expected: "Juan Testing Again & Again" Name textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Juan Testing Again & Again Name textbox value matched as expected'); + } + }, + + //Source URL label + { + description: 'Validate Source URL label', + action: async () => { + const elementText = await driver.findElement(By.css('#divsource > .form-label')).getText(); + if (elementText !== 'Source URL') { + throw new Error(`Expected: "Source URL" label text; Actual: "${elementText}"`); + } + console.log('Passed: Source URL label text matched as expected'); + } + }, + + //Source URL textbox + { + description: 'Validate Source URL textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#url')).getText(); + if (elementValue !== '') { + throw new Error(`Expected: "https://www.espn.com" Source URL textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: https://www.espn.com Source URL textbox value matched as expected'); + } + }, + + //Parent label + { + description: 'Validate Parent label', + action: async () => { + const elementText = await driver.findElement(By.css('#divparent > .form-label')).getText(); + if (elementText !== 'Parent') { + throw new Error(`Expected: "Parent" label text; Actual: "${elementText}"`); + } + console.log('Passed: Parent label text matched as expected'); + } + }, + + //Parent Info icon is present + { + description: 'Verify Parent Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divparent .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Parent Info icon is not present'); + } + console.log('Passed: Parent Info icon is present'); + } + }, + + //Parent dropdown "My Latest Organization For Now" (873617737) + { + description: 'Validate Parent dropdown option', + action: async () => { + const elementOption = await driver.findElement(By.css('#parent')).getAttribute('value'); + if (elementOption !== '873617737') { + throw new Error(`Expected: "My Latest Organization For Now"; Actual: "${elementOption}"`); + } + console.log('Passed: My Latest Organization For Now dropdown option matched as expected'); + } + }, + + //Description label + { + description: 'Validate Description label', + action: async () => { + const elementText = await driver.findElement(By.css('#divdescription > .form-label')).getText(); + if (elementText !== 'Description') { + throw new Error(`Expected: "Description" label text; Actual: "${elementText}"`); + } + console.log('Passed: Description label text matched as expected'); + } + }, + + //Description textbox value + { + description: 'Validate Description textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#description')).getText(); + if (elementValue !== 'This is my Framework testing description.') { + throw new Error(`Expected: "This is my Framework testing description." Description textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Description textbox value matched as expected'); + } + }, + + //Creator label + { + description: 'Validate Creator label', + action: async () => { + const elementText = await driver.findElement(By.css('#divcreator > .form-label')).getText(); + if (elementText !== 'Creator') { + throw new Error(`Expected: "Creator" label text; Actual: "${elementText}"`); + } + console.log('Passed: Creator label text matched as expected'); + } + }, + + //Creator Info icon is present + { + description: 'Verify Creator Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divcreator .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Creator Info icon is not present'); + } + console.log('Passed: Creator Info icon is present'); + } + }, + + //Creator textbox value + { + description: 'Validate Creator textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#creator')).getAttribute('value'); + if (elementValue !== 'Juancho') { + throw new Error(`Expected: "Juancho" Creator textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Creator textbox value matched as expected'); + } + }, + + //Publisher label + { + description: 'Validate Publisher label', + action: async () => { + const elementText = await driver.findElement(By.css('#divpublisher > .form-label')).getText(); + if (elementText !== 'Publisher') { + throw new Error(`Expected: "Publisher" label text; Actual: "${elementText}"`); + } + console.log('Passed: Publisher label text matched as expected'); + } + }, + + //Publisher Info icon is present + { + description: 'Verify Publisher Info icon is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('#divpublisher .fa')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Publisher Info icon is not present'); + } + console.log('Passed: Publisher Info icon is present'); + } + }, + + //Publisher textbox value + { + description: 'Validate Publisher textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#creator')).getAttribute('value'); + if (elementValue !== 'Juancho') { + throw new Error(`Expected: "Juancho" Publisher textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Publisher textbox value matched as expected'); + } + }, + + //Status label + { + description: 'Validate Status label', + action: async () => { + const elementText = await driver.findElement(By.css('#divstatus > .form-label')).getText(); + if (elementText !== 'Status') { + throw new Error(`Expected: "Status" label text; Actual: "${elementText}"`); + } + console.log('Passed: Status label text matched as expected'); + } + }, + + //Status dropdown + { + description: 'Validate Status dropdown option', + action: async () => { + const elementText = await driver.findElement(By.css('#status > option:nth-child(1)')).getText(); + if (elementText !== 'Draft') { + throw new Error(`Expected: "Draft" Status value text; Actual: "${elementText}"`); + } + console.log('Passed: Draft Status value text matched as expected'); + } + }, + + //Effective Date label + { + description: 'Validate Effective Date label', + action: async () => { + const elementText = await driver.findElement(By.css('#diveffective > .form-label')).getText(); + if (elementText !== 'Effective Date') { + throw new Error(`Expected: "Effective Date" label text; Actual: "${elementText}"`); + } + console.log('Passed: Effective Date label text matched as expected'); + } + }, + + //Effective Date textbox + { + description: 'Validate Effective Date textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#effective')).getAttribute('value'); + if (elementValue !== '12/02/2022') { + throw new Error(`Expected: "12/02/2022" Effective Date textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: 12/02/2022 Effective Date textbox value matched as expected'); + } + }, + + //Language label + { + description: 'Validate Language label', + action: async () => { + const elementText = await driver.findElement(By.css('#divlang > .form-label')).getText(); + if (elementText !== 'Language') { + throw new Error(`Expected: "Language" label text; Actual: "${elementText}"`); + } + console.log('Passed: Language label text matched as expected'); + } + }, + + //Language dropdown + { + description: 'Validate Language dropdown option', + action: async () => { + const elementOption = await driver.findElement(By.css('#lang')).getAttribute('value'); + if (elementOption !== 'en') { + throw new Error(`Expected: "English"; Actual: "${elementOption}"`); + } + console.log('Passed: English dropdown option matched as expected'); + } + }, + + //Version label + { + description: 'Validate Version label', + action: async () => { + const elementText = await driver.findElement(By.css('#divversion > .form-label')).getText(); + if (elementText !== 'Version') { + throw new Error(`Expected: "Version" label text; Actual: "${elementText}"`); + } + console.log('Passed: Version label text matched as expected'); + } + }, + + //Version textbox + { + description: 'Validate Version textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#version')).getAttribute('value'); + if (elementValue !== '2022.1.1') { + throw new Error(`Expected: "2022.1.1" Version textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: 2022.1.1 Version textbox value matched as expected'); + } + }, + + //Notes label + { + description: 'Validate Notes label', + action: async () => { + const elementText = await driver.findElement(By.css('#divnotes > .form-label')).getText(); + if (elementText !== 'Notes') { + throw new Error(`Expected: "Notes" label text; Actual: "${elementText}"`); + } + console.log('Passed: Notes label text matched as expected'); + } + }, + + //Notes textbox value + { + description: 'Validate Notes textbox value', + action: async () => { + const elementValue = await driver.findElement(By.css('#notes')).getText(); + if (elementValue !== 'This only contains Kindergarten for now.') { + throw new Error(`Expected: "This only contains Kindergarten for now." Notes textbox value; Actual: "${elementValue}"`); + } + console.log('Passed: Notes textbox value matched as expected'); + } + }, + + //Delete button text + { + description: 'Validate Delete button text', + action: async () => { + const elementText = await driver.findElement(By.css('#orgdelete')).getText(); + if (elementText !== 'Delete') { + throw new Error(`Expected: "Delete" button text; Actual: "${elementText}"`); + } + console.log('Passed: Delete button text matched as expected'); + } + }, + + //Delete button color -red + { + description: 'Validate Delete button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#orgdelete')).getCssValue('background-color'); + if (elementStyle !== 'rgba(220, 53, 69, 1)') { + throw new Error(`Delete button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Delete button color matched as expected'); + } + }, + + //Save button text + { + description: 'Validate Save button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalop')).getAttribute('value'); + if (elementText !== 'Save') { + throw new Error(`Expected: "Save" button text; Actual: "${elementText}"`); + } + console.log('Passed: Save button text matched as expected'); + } + }, + + //Save button color -green + { + description: 'Validate Save button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalop')).getCssValue('background-color'); + if (elementStyle !== 'rgba(48, 200, 172, 1)') { + throw new Error(`Save button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Save button color matched as expected'); + } + }, + + //Close button text + { + description: 'Validate Close button text', + action: async () => { + const elementText = await driver.findElement(By.css('#modalclose')).getText(); + if (elementText !== 'Close') { + throw new Error(`Expected: "Close" button text; Actual: "${elementText}"`); + } + console.log('Passed: Close button text matched as expected'); + } + }, + + //Close button color -white + { + description: 'Validate Close button color', + action: async () => { + const elementStyle = await driver.findElement(By.css('#modalclose')).getCssValue('background-color'); + if (elementStyle !== 'rgba(0, 0, 0, 0)') { + throw new Error(`Close button color did not match; Actual: "${elementStyle}"`); + } + console.log('Passed: Close button color matched as expected'); + } + }, + + //NEXT ACTION - Close DIV + { description: 'Click Close button', action: async () => await driver.findElement(By.css('#modalclose')).click() }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, //LOG OUT //NEXT ACTION - Log out { description: 'Click Username dropdown', action: async () => await driver.findElement(By.css('#navbarDropdown > span')).click() }, - { description: 'Wait action to complete', action: async () => await driver.sleep(2000) }, + { description: 'Wait for action to complete', action: async () => await driver.sleep(2000) }, //Log Out icon { @@ -299,6 +3788,18 @@ const steps = [ } }, + //Log Out button + { + description: 'Verify Log Out button is present', + action: async () => + { const expectedIcon = await driver.wait(until.elementLocated(By.css('.login')), 5000).catch(() => false); + if (!expectedIcon) { + throw new Error('Log Out button not found'); + } + console.log('Passed: Log Out button present; Script completed'); + } + }, + ]; const logStep = (worksheet, stepDescription, status, stepIndex, timestamp, screenshotPath) => { @@ -346,6 +3847,8 @@ try { // Log test start time worksheet = logStep(worksheet, 'Test Start', 'Started', '', startTime, ''); + let allStepsPassed = true; + for (const step of steps) { const stepIndex = steps.indexOf(step) + 1; const timestamp = new Date().toISOString(); @@ -359,17 +3862,18 @@ try { worksheet = logStep(worksheet, step.description, 'Failed', stepIndex, timestamp, screenshotPath); console.error(`Step ${stepIndex} FAILED: ${error.message}`); testStatus = 'Failed'; + allStepsPassed = false; } } //Check if login was successful const loginButton = await driver.wait(until.elementLocated(By.css('.login')), 5000).catch(() => false); - if (loginButton) { - console.log('COMPLETED Script: frameworkManagementPage'); + if (loginButton & allStepsPassed) { + console.log('PASSED: Framework Management Page(ExACT_frameworkManagementPage); All test steps completed successfully'); testStatus = 'Passed'; } else { - console.log('FAILED: Unable to complete frameworkManagementPage script'); + console.log('FAILED: Framework Management Page(ExACT_frameworkManagementPage); One or more test steps failed'); testStatus = 'Failed'; }