Produced by Araxis Merge on 6/21/2017 10:24:32 AM 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 | JLV_2.5.3.0.2_cif.zip\JLV_2.5.3.0.2_src\BHIERelayService\src\test\java\gov\va\med\bhie\patient | NoteDaoTest.java | Wed Jun 7 15:11:32 2017 UTC |
2 | JLV_2.5.3.0.2_cif.zip\JLV_2.5.3.0.2_src\BHIERelayService\src\test\java\gov\va\med\bhie\patient | NoteDaoTest.java | Wed Jun 21 13:53:24 2017 UTC |
Description | Between Files 1 and 2 |
|
---|---|---|
Text Blocks | Lines | |
Unchanged | 2 | 254 |
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 | /** | |
2 | * Janus 4 .0 (c) | |
3 | * Copyrig ht (c) 201 1 Hawaii R esource Gr oup LLC. A ll Rights Reserved. | |
4 | * Develop ed for the Pacific T elehealth & Technolo gy Hui and the Pacif ic Joint I nformation Technolog y Center | |
5 | * Contrib utors: | |
6 | * Hon orable Sen ator Danie l K. Inouy e | |
7 | * VA Pacific Is lands Heal th Care Sy stem | |
8 | * Tri pler Army Medical Ce nter | |
9 | */ | |
10 | ||
11 | ||
12 | package go v.va.med.b hie.patien t; | |
13 | ||
14 | import gov .va.med.bh ie.BaseTes t; | |
15 | import gov .va.med.bh ie.beans.N oteImage; | |
16 | import gov .va.med.bh ie.common. ClinicalDo mainLoincC ode; | |
17 | import gov .va.med.bh ie.dao.Dao Exception; | |
18 | import gov .va.med.bh ie.dao.pat ient.NoteD ao; | |
19 | import gov .va.med.bh ie.dao.pat ient.V4Dao ; | |
20 | import gov .va.med.bh ie.resultc ollection. V4ResultCo llection; | |
21 | import org .junit.Tes t; | |
22 | ||
23 | import sta tic org.ju nit.Assert .assertTru e; | |
24 | ||
25 | public cla ss NoteDao Test exten ds BaseTes t | |
26 | { | |
27 | @Test | |
28 | public void test GetPatient Notes() th rows DaoEx ception { | |
29 | ||
30 | // NoteDao no teDao = ne w NoteDao( ); | |
31 | // NoteResult Collection V3 noteRes ults = not eDao.getPa tientNotes V3(queryBe an); | |
32 | // | |
33 | // //long sti me = logRe quest(quer yBean); | |
34 | // String tok en = ""; | |
35 | // try { | |
36 | // NoteRe sultCollec tionV3 rtc ; | |
37 | // int co unt = 0; | |
38 | // //rtc = BHIELimi t.getInsta nce().getP atientNote sCache(que ryBean); | |
39 | // //if ( rtc == nul l) { | |
40 | // // token = BH IELimit.ge tInstance( ).getToken (); | |
41 | // rt c = noteDa o.getPatie ntNotesV3( queryBean) ; | |
42 | // // if (rtc != null && r tc.getData RecordList () != null ) { | |
43 | // // count = rtc.getD ataRecordL ist().size (); | |
44 | // // } | |
45 | // // logRespons e(queryBea n, "", rtc , count, s time, "fal se"); | |
46 | // // BHIELimit. getInstanc e().putPat ientNotesC ache(query Bean, rtc) ; | |
47 | // //} el se { | |
48 | // // logRespons e(queryBea n, "", rtc , rtc.getD ataRecordL ist().size (), stime, "true"); | |
49 | // //} | |
50 | // // retu rn rtc; | |
51 | // } catch (E xception e ) { | |
52 | // //logR esponse(qu eryBean, e .getLocali zedMessage (), null, 0, stime, "false"); | |
53 | // throw new Runtim eException (e); | |
54 | // } finally { | |
55 | // BHIELi mit.getIns tance().re leaseToken (token); | |
56 | // } | |
57 | // | |
58 | // assertTrue (noteResul ts.getData RecordList ().size() > 0); | |
59 | } | |
60 | ||
61 | @Test | |
62 | public void test GetPatient NotesV4() throws Dao Exception { | |
63 | V4 Dao v4Dao = new V4Da o(); | |
64 | V4 ResultColl ection v4R esults = v 4Dao.getV4 Data(Clini calDomainL oincCode.N OTES, quer yBean); | |
65 | as sertTrue(v 4Results.g etDataReco rdList().g etAllergy( ).size() > 0); | |
66 | } | |
67 | ||
68 | @Test | |
69 | public void test GetEncount erNotes() throws Dao Exception { | |
70 | ||
71 | No teDao note Dao = new NoteDao(); | |
72 | // NoteResult Collection V3 noteRes ults = not eDao.getEn counterNot esV3(query Bean); | |
73 | // assertTrue (noteResul ts.getData RecordList ().size() > 0); | |
74 | } | |
75 | ||
76 | @Test | |
77 | public void test GetNoteIma ge() throw s DaoExcep tion { | |
78 | ||
79 | No teDao note Dao = new NoteDao(); | |
80 | No teImage re sponse = n oteDao.get NoteImage( "215286578 7"); | |
81 | as sertTrue(r esponse.ge tNoteBytes ().length > 0); | |
82 | } | |
83 | ||
84 | @Test | |
85 | public void test GetNoteIma geFromUrl( ) throws D aoExceptio n { | |
86 | ||
87 | No teDao note Dao = new NoteDao(); | |
88 | Il legalArgum entExcepti on iae = n ull; | |
89 | tr y | |
90 | { | |
91 | NoteImage ni = noteD ao.getNote ImageFromU rl("http:/ / IP /MockDoDAd aptor/asyn c/complex/ note/21575 65489"); | |
92 | ni.getCo ntentType( ); | |
93 | } | |
94 | ca tch (Illeg alArgument Exception e) | |
95 | { | |
96 | iae = e; | |
97 | } | |
98 | ||
99 | as sertTrue(i ae != null ); | |
100 | ||
101 | ia e = null; | |
102 | ||
103 | tr y | |
104 | { | |
105 | noteDao. getNoteIma geFromUrl( "http://BH IEdomain/a sync/comet ?loinc=123 4&userid=1 2345"); | |
106 | } | |
107 | ca tch (Illeg alArgument Exception e) | |
108 | { | |
109 | iae = e; | |
110 | } | |
111 | ||
112 | as sertTrue(i ae != null ); | |
113 | ||
114 | ia e = null; | |
115 | ||
116 | No teImage re sponse = n oteDao.get NoteImageF romUrl("ht tp://BHIEd omain:8080 /async/com plex/note/ 2157580439 "); | |
117 | as sertTrue(r esponse.ge tNoteBytes ().length > 0); | |
118 | } | |
119 | ||
120 | ||
121 | // @Tes t | |
122 | // publ ic void te stGetPatie ntConsults () throws DaoExcepti on { | |
123 | // | |
124 | // NoteDao no teDao = ne w NoteDao( ); | |
125 | // NoteResult Collection V3 noteRes ults = not eDao.getPa tientConsu ltsV3(quer yBean); | |
126 | // assertTrue (noteResul ts.getData RecordList ().size() > 0); | |
127 | // } | |
128 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.