Produced by Araxis Merge on 3/13/2018 7:47:51 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 | TASCore_v1.0_Build_2_Jan_2018.zip\MCCF_EDI_TAS_WebUI\src\app\core\maincontent | maincontent.service.spec.ts | Thu Feb 15 21:16:38 2018 UTC |
| 2 | TASCore_v1.0_Build_2_Jan_2018.zip\MCCF_EDI_TAS_WebUI\src\app\core\maincontent | maincontent.service.spec.ts | Thu Mar 8 19:56:21 2018 UTC |
| Description | Between Files 1 and 2 |
|
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 10 | 202 |
| Changed | 9 | 20 |
| 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 | import {in ject, Test Bed} from '@angular/ core/testi ng' | |
| 2 | import {Mo ckBackend, MockConne ction} fro m '@angula r/http/tes ting' | |
| 3 | import {Ba seRequestO ptions, Ht tp, Respon se, Respon seOptions} from '@an gular/http ' | |
| 4 | ||
| 5 | import {Ma inContentS ervice} fr om './main content.se rvice' | |
| 6 | import {Ma inContent} from './m aincontent ' | |
| 7 | ||
| 8 | describe(' MainConten tService', function () { | |
| 9 | let subj ect: MainC ontentServ ice | |
| 10 | let back end: MockB ackend | |
| 11 | ||
| 12 | beforeEa ch(functio n () { | |
| 13 | ||
| 14 | TestBe d.configur eTestingMo dule({ | |
| 15 | prov iders: [ | |
| 16 | Ma inContentS ervice, | |
| 17 | Mo ckBackend, | |
| 18 | Ba seRequestO ptions, | |
| 19 | { | |
| 20 | provide: H ttp, | |
| 21 | useFactory : function (mockBack end, defau ltOptions) { | |
| 22 | return n ew Http(mo ckBackend, defaultOp tions); | |
| 23 | }, | |
| 24 | deps: [Moc kBackend, BaseReques tOptions] | |
| 25 | } | |
| 26 | ] | |
| 27 | }) | |
| 28 | ||
| 29 | }) | |
| 30 | ||
| 31 | beforeEa ch(inject( [MainConte ntService, MockBacke nd], funct ion (mainC ontentServ ice, mockB ackend) { | |
| 32 | subjec t = mainCo ntentServi ce | |
| 33 | backen d = mockBa ckend | |
| 34 | })) | |
| 35 | ||
| 36 | it('shoul d get data ', functio n (done) { | |
| 37 | ||
| 38 | backen d.connecti ons.subscr ibe(functi on (connec tion: Mock Connection ) { | |
| 39 | ||
| 40 | let options = new Respon seOptions( { | |
| 41 | bo dy: { | |
| 42 | "items": [ | |
| 43 | { | |
| 44 | "colle ction": "m aincontent ", | |
| 45 | "id": "default_m aincontent ", | |
| 46 | "item" : { | |
| 47 | "pro duct": [ | |
| 48 | { | |
| 49 | "name": "h ome", | |
| 50 | "erevenueU rl": "http s:// URL /sites/eBu sinessSolu tions/Site Pages/Home .aspx" | |
| 51 | }, | |
| 52 | { | |
| 53 | "name": "e Billing", | |
| 54 | "erevenueU rl": "http s:// URL /sites/eBu sinessSolu tions/Site Pages/More Proj.aspx? qproj=eBil ling" | |
| 55 | }, | |
| 56 | { | |
| 57 | "name": "e Insurance" , | |
| 58 | "erevenueU rl": "http s:// URL /sites/eBu sinessSolu tions/Site Pages/More Proj.aspx? qproj=eIns urance" | |
| 59 | }, | |
| 60 | { | |
| 61 | "name": "e Pharmacy", | |
| 62 | "erevenueU rl": "http s:// URL /sites/eBu sinessSolu tions/Site Pages/More Proj.aspx? qproj=ePha rmacy" | |
| 63 | }, | |
| 64 | { | |
| 65 | "name": "e Payments", | |
| 66 | "erevenueU rl": "http s:// URL /sites/eBu sinessSolu tions/Site Pages/More Proj.aspx? qproj=ePay ments" | |
| 67 | }, | |
| 68 | { | |
| 69 | "name": "N PI", | |
| 70 | "erevenueU rl": "http s:// URL /sites/eBu sinessSolu tions/Site Pages/More Proj.aspx? qproj=NPI" | |
| 71 | }, | |
| 72 | { | |
| 73 | "name": "N on-MCCF", | |
| 74 | "erevenueU rl": "http s:// URL /sites/eBu sinessSolu tions/Site Pages/More Proj.aspx? qproj=Tric areChampva " | |
| 75 | }, | |
| 76 | { | |
| 77 | "name": "e Admin", | |
| 78 | "erevenueU rl": "http s:// URL /sites/eBu sinessSolu tions/Site Pages/Home .aspx" | |
| 79 | } | |
| 80 | ], | |
| 81 | "pho ne": "(800 ) 555-5555 ", | |
| 82 | "emailText ": " PII ", | |
| 83 | "emailValu e": " PII ", | |
| 84 | "hel pContent": "help lin e 1<br> he lp line2<b r> <p>dial <b>9-1-1< /b> for an emergency </p><br><I >Thank you !</I>" | |
| 85 | } | |
| 86 | } | |
| 87 | ], | |
| 88 | "total": 1 | |
| 89 | } | |
| 90 | }) | |
| 91 | conn ection.moc kRespond(n ew Respons e(options) ) | |
| 92 | }) | |
| 93 | ||
| 94 | subjec t.getConte nt().subsc ribe(funct ion (respo nse) { | |
| 95 | ex pect(respo nse).toEqu al(jasmine .any(MainC ontent)) | |
| 96 | ex pect(respo nse.produc t.length). toEqual(8) | |
| 97 | ex pect(respo nse.produc t[0].name) .toEqual(' home') | |
| 98 | }, | |
| 99 | func tion (e) { | |
| 100 | fa il(e); | |
| 101 | } | |
| 102 | ); | |
| 103 | ||
| 104 | done() | |
| 105 | }) | |
| 106 | ||
| 107 | afterEac h(function () { | |
| 108 | TestBe d.resetTes tingModule () | |
| 109 | }) | |
| 110 | ||
| 111 | }) |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.