Produced by Araxis Merge on 5/29/2018 12:14:35 PM Central Daylight Time. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.
| # | Location | File | Last Modified |
|---|---|---|---|
| 1 | mobile-kidney-web-2.0.0.zip\mobile-kidney-web\acceptance_test\watir\spec\learn-more | Pharmacy_Prescribed_OTC_Medication_Content_DCKDA_946_spec.rb | Wed Apr 4 20:16:46 2018 UTC |
| 2 | mobile-kidney-web-2.0.0.zip\mobile-kidney-web\acceptance_test\watir\spec\learn-more | Pharmacy_Prescribed_OTC_Medication_Content_DCKDA_946_spec.rb | Tue May 29 16:01:11 2018 UTC |
| Description | Between Files 1 and 2 |
|
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 2 | 318 |
| Changed | 1 | 2 |
| Inserted | 0 | 0 |
| Removed | 0 | 0 |
| Whitespace | |
|---|---|
| Character case | Differences in character case are significant |
| Line endings | Differences in line endings (CR and LF characters) are ignored |
| CR/LF characters | Not shown in the comparison detail |
No regular expressions were active.
| 1 | #!/bin/env ruby | |
| 2 | # encoding : utf-8 | |
| 3 | ||
| 4 | require 'r ubygems' | |
| 5 | require 'r spec' | |
| 6 | require 'w atir-webdr iver' | |
| 7 | require 'p age-object ' | |
| 8 | require 's preadsheet ' | |
| 9 | ||
| 10 | require_re lative '.. /rspec_hel per' | |
| 11 | require_re lative '.. /../lib/pa ges/login_ page' | |
| 12 | require_re lative '.. /../lib/pa ges/eula' | |
| 13 | require_re lative '.. /../lib/pa ges/landin g_page' | |
| 14 | require_re lative '.. /../lib/pa ges/roa' | |
| 15 | require_re lative '.. /../lib/pa ges/launch pad' | |
| 16 | require_re lative '.. /../lib/pa ges/common _elements' | |
| 17 | require_re lative '.. /../lib/pa ges/common _tests' | |
| 18 | require_re lative '.. /../lib/pa ges/modal_ dialog' | |
| 19 | require_re lative '.. /../lib/pa ges/left_s ide_nav' | |
| 20 | require_re lative '.. /../lib/pa ges/learn_ more_accor dions' | |
| 21 | ||
| 22 | describe ' Story#DCKD A-946 Phar macy_Presc ribed_OTC_ Medication _Content_D CKDA_946_s pec.rb', : regression => true d o | |
| 23 | include DriverOper ationsModu le | |
| 24 | ||
| 25 | headingN ame = "Tak ing Prescr ibed and O TC Medicat ions" | |
| 26 | ||
| 27 | before(: all) do | |
| 28 | ||
| 29 | initia lizeConfig urations() | |
| 30 | ||
| 31 | @commo nElements = CommonEl ement.new( @driver) | |
| 32 | @login page = Log inPage.new (@driver) | |
| 33 | @eula = Eula.new (@driver) | |
| 34 | @landi ng = Landi ngPage.new (@driver) | |
| 35 | @roa = Roa.new(@ driver) | |
| 36 | @leftn av = LeftS ideNav.new (@driver) | |
| 37 | @lp = Launchpad. new(@drive r) | |
| 38 | @commo nTest = Co mmonTest.n ew(@driver ) | |
| 39 | @modal = Modal.n ew(@driver ) | |
| 40 | @lmAcc d = LearnM oreAccd.ne w(@driver) | |
| 41 | ||
| 42 | @commonTes t.passByLa ndingPageA ndAuthenti cate(" AI ", " AI ", "patien t01, zztes t", "D1234 01") | |
| 43 | begin | |
| 44 | Wati r::Wait.un til | |
| 45 | @com monElement s.angulart itle_eleme nt.visible ? | |
| 46 | rescue | |
| 47 | Wati r::Wait::T imeoutErro r | |
| 48 | unti l | |
| 49 | @com monElement s.angulart itle_eleme nt.visible ? | |
| 50 | end | |
| 51 | end | |
| 52 | ||
| 53 | @commo nTest.wait ForContent LoadedSumm aryPage | |
| 54 | @leftn av.leftSid eNav | |
| 55 | ||
| 56 | @commo nTest.navi gateToAsub Feature("L earnMore", ".pharmac y") | |
| 57 | ||
| 58 | @leftn av.clickAc cordion(1) | |
| 59 | sleep 0.5 | |
| 60 | end | |
| 61 | ||
| 62 | after(:a ll) do | |
| 63 | @drive r.close | |
| 64 | end | |
| 65 | ||
| 66 | dataShee tFilePath = File.dir name(__FIL E__) + '/. ./../datas heet/Pharm acy_Text_C ontent.xls ' | |
| 67 | book = S preadsheet .open data SheetFileP ath | |
| 68 | sheet1 = book.work sheet 'otc Medication s' | |
| 69 | ||
| 70 | counter = 0 | |
| 71 | sheet1.e ach 1 do | row| | |
| 72 | counte r = counte r + 1 | |
| 73 | ||
| 74 | rowLen gth = row. length | |
| 75 | ||
| 76 | sectio nID = row[ 0].to_i | |
| 77 | expect edImageInf o = row[2] .split(/\r ?\n/) | |
| 78 | expect edImgName = expected ImageInfo. first | |
| 79 | expect edImgAckno wledgement = "" | |
| 80 | if exp ectedImage Info.lengt h > 1 | |
| 81 | expe ctedImgAck nowledgeme nt = expec tedImageIn fo.last | |
| 82 | end | |
| 83 | ||
| 84 | expect edImgAltNa me = row[3 ] | |
| 85 | expect edSectionH eader = ro w[4] | |
| 86 | ||
| 87 | contex t 'AC#DCKD A-947~959| TC#DCKDA-5 26: Image and conten t for this section d isplays co rrectly - ' + expect edSectionH eader do | |
| 88 | ||
| 89 | if r ow[2] != " na" | |
| 90 | it '. Verify the image file name is correc t: ' do | |
| 91 | if @lmAccd .getImgtUn derEachSec tion(secti onID, head ingName).i nclude?(ex pectedImgN ame) == fa lse | |
| 92 | puts "Di fferent! F ailed sect ionID=" + sectionID. to_s + "; Displayed Img=" + @l mAccd.getI mgtUnderEa chSection( sectionID, headingNa me).to_s + ", expect ed " + exp ectedImgNa me | |
| 93 | end | |
| 94 | expect(@lm Accd.getIm gtUnderEac hSection(s ectionID, headingNam e).include ?(expected ImgName)). to eq(true ) | |
| 95 | en d | |
| 96 | ||
| 97 | it '. Verify that the image has the correc t alt text . ' do | |
| 98 | if @lmAccd .getImgAlt TextUnderE achSection (sectionID , headingN ame).inclu de?(expect edImgAltNa me) == fal se | |
| 99 | puts "Di fferent! F ailed sect ionID=" + sectionID. to_s + "; Displayed alt text=" + @lmAccd .getImgAlt TextUnderE achSection (sectionID , headingN ame) | |
| 100 | puts "\n \nExpected =" + expec tedImgAltN ame | |
| 101 | end | |
| 102 | expect(@lm Accd.getIm gAltTextUn derEachSec tion(secti onID, head ingName).i nclude?(ex pectedImgA ltName)).t o eq(true) | |
| 103 | en d | |
| 104 | ||
| 105 | it '. Verify the image acknowled gement is correct: ' do | |
| 106 | expect(@lm Accd.getIm gAcknowled gementUnde rEachSecti on(section ID, headin gName)).to eq(expect edImgAckno wledgement ) | |
| 107 | en d | |
| 108 | ||
| 109 | it '. Click the image and verify it opens up in a mo dal screen . ' do | |
| 110 | @lmAccd.cl ickImgtUnd erEachSect ion(sectio nID, headi ngName) | |
| 111 | @modal.img Title_elem ent.when_v isible(tim eout=10) | |
| 112 | expect(@mo dal.imgTit le).to eq( expectedSe ctionHeade r) | |
| 113 | expect(@mo dal.closeI mg?).to eq (true) | |
| 114 | @modal.clo seImg | |
| 115 | @modal.img Title_elem ent.when_n ot_visible | |
| 116 | expect(@mo dal.imgTit le?).to eq (false) | |
| 117 | en d | |
| 118 | ||
| 119 | it '. Verify that the segment he ader displ ays correc tly. ' do | |
| 120 | $bodyConte nt = @lmAc cd.getBody ContentUnd erEachSect ion(sectio nID, headi ngName) | |
| 121 | expect($bo dyContent. include?(e xpectedSec tionHeader )).to eq(t rue) | |
| 122 | en d | |
| 123 | ||
| 124 | it '. Verify the in Ph one form f actor, the image doe s not disp lay. ' do | |
| 125 | resizeWind owTo(320, 480) | |
| 126 | sleep 1 | |
| 127 | expect(@lm Accd.isImg Present(se ctionID, h eadingName )).to eq(f alse) | |
| 128 | ||
| 129 | resizeWind owToDefaul t() | |
| 130 | en d | |
| 131 | ||
| 132 | it '. Verify that all segments u nder this section di splays cor rectly. ' do | |
| 133 | ||
| 134 | $bodyConte nt = @lmAc cd.getBody ContentUnd erEachSect ion(sectio nID, headi ngName) | |
| 135 | ||
| 136 | dataFileCo ntent = ex pectedSect ionHeader | |
| 137 | for column in 5..row Length-1 | |
| 138 | if row[c olumn] | |
| 139 | ||
| 140 | expected SegContent = row[col umn].strip | |
| 141 | dataFile Content += expectedS egContent | |
| 142 | end | |
| 143 | end | |
| 144 | ||
| 145 | totalBodyC ontent = $ bodyConten t.delete!( "\n") | |
| 146 | ||
| 147 | expect(dat aFileConte nt).to eq( totalBodyC ontent) | |
| 148 | end | |
| 149 | ||
| 150 | else | |
| 151 | ||
| 152 | it '. Verify the Knowl edge Check text disp lays. ' do | |
| 153 | $bodyConte nt = @lmAc cd.getBody ContentUnd erEachSect ion(sectio nID, headi ngName) | |
| 154 | expect($bo dyContent. include?(e xpectedSec tionHeader )).to eq(t rue) | |
| 155 | en d | |
| 156 | end | |
| 157 | end | |
| 158 | end | |
| 159 | ||
| 160 | end |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.