4039. EPMO Open Source Coordination Office Redaction File Detail Report

Produced by Araxis Merge on 6/9/2017 3:51:15 PM Eastern 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.

4039.1 Files compared

# Location File Last Modified
1 Fri Jun 9 19:51:15 2017 UTC
2 eHealth_Exch (eHealth Exchange Enhancements) Build 3 docs & code_May_2017.zip\VAP_CIF_CODE0502.zip\VAP_CIF_CODE0502\VAP_CIF_CODE0502\nvap-server\src\test\java\gov\va\nvap\service\permission SimplePDPTester.java Fri Apr 21 20:03:30 2017 UTC

4039.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 0 0
Changed 0 0
Inserted 1 257
Removed 0 0

4039.3 Comparison options

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

4039.4 Active regular expressions

No regular expressions were active.

4039.5 Comparison detail

        1   package go v.va.nvap. service.pe rmission;
        2  
        3  
        4   import oas is.names.t c.xacml._2 _0.context .schema.os .DecisionT ype;
        5   import oas is.names.t c.xacml._2 _0.context .schema.os .RequestTy pe;
        6   import oas is.names.t c.xacml._2 _0.context .schema.os .ResponseT ype;
        7  
        8   import org .junit.Aft er;
        9   import org .junit.Aft erClass;
        10   import org .junit.Bef ore;
        11   import org .junit.Bef oreClass;
        12   import org .junit.Tes t;
        13   import jun it.framewo rk.Assert;
        14  
        15   import gov .va.nvap.s erver.serv ice.permis sion.pdp.P DPImplJava ;
        16  
        17   public cla ss SimpleP DPTester {
        18           
        19           pr ivate PDPI mplJava si mplePDP =  new PDPImp lJava();
        20           
        21           pu blic Simpl ePDPTester () {
        22                    simp lePDP.setL ocalHomeCo mmunityId( "2.16.840. 1.113883.4 .349");
        23                    simp lePDP.setN oOptInRequ iredHomeCo mmunities( new String [] {"2.16. 840.1.1138 83.3.42.10 001.100001 .12"});
        24                    simp lePDP.setP atientPurp oseOfUse(n ew String[ ] {"TREATM ENT","EMER GENCY"});
        25           }
        26  
        27           @B eforeClass
        28           pu blic stati c void set UpBeforeCl ass() thro ws Excepti on {
        29           }
        30  
        31           @A fterClass
        32           pu blic stati c void tea rDownAfter Class() th rows Excep tion {
        33           }
        34  
        35           @B efore
        36           pu blic void  setUp() th rows Excep tion {
        37           }
        38  
        39           @A fter
        40           pu blic void  tearDown()  throws Ex ception {
        41           }
        42           
        43           /*  --------- ---------- ----
        44            *  Valid Req uest Types  
        45            *  --------- ---------- ----
        46            * /
        47           
        48           
        49           @T est
        50           pu blic void  testValidI nboundDocQ ueryInByDO DRequestor NoOptIn()  {
        51                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidInboun dDocQueryI nByDODRequ estorNoOpt In();
        52                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        53                    Asse rt.assertT rue("Valid  Inbound D oc Query B y DOD Requ estor - no t opted in ", 
        54                                      response .getResult ().get(0). getDecisio n() ==
        55                                 De cisionType .PERMIT);
        56           }
        57           
        58           @T est
        59           pu blic void  testValidI nboundDocQ ueryInByDO DRequestor WithOptIn( ) {
        60                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidInboun dDocQueryI nByDODRequ estorWithO ptIn();
        61                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        62                    Asse rt.assertT rue("Valid  Inbound D oc Query B y DOD Requ estor - op ted in", 
        63                                      response .getResult ().get(0). getDecisio n() ==
        64                                 De cisionType .PERMIT);
        65           }
        66  
        67  
        68           @T est
        69           pu blic void  testValidI nboundDocQ ueryInByNo nDODReques torWithOpt In() {
        70                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidInboun dDocQueryI nByNonDODR equestorWi thOptIn();
        71                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        72                    Asse rt.assertT rue("Valid  Inbound D oc Query B y Non DOD  Requestor  - opted in ", 
        73                                      response .getResult ().get(0). getDecisio n() ==
        74                                 De cisionType .PERMIT);
        75           }
        76           
        77           @T est
        78           pu blic void  testValidI nboundDocR etrieveInB yNonDODReq uestorWith OptIn() {
        79                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidInboun dDocRetrie veInByNonD ODRequesto rWithOptIn ();
        80                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        81                    Asse rt.assertT rue("Valid  Inbound D oc Retriev e By Non D OD Request or - opted  in", 
        82                                      response .getResult ().get(0). getDecisio n() ==
        83                                 De cisionType .PERMIT);
        84           }
        85           
        86           @T est
        87           pu blic void  testValidI nboundPati entDiscove ryInByNonD ODRequesto rWithOptIn () {
        88                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidInboun dPatientDi scoveryInB yNonDODReq uestorWith OptIn();
        89                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        90                    Asse rt.assertT rue("Valid  Inbound P atient Dis covery By  Non DOD Re questor -  opted in",  
        91                                      response .getResult ().get(0). getDecisio n() ==
        92                                 De cisionType .PERMIT);
        93           }
        94  
        95  
        96           @T est
        97           pu blic void  testValidO utboundDoc QueryOutBy DODRequest orNoOptIn( ) {
        98                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidOutbou ndDocQuery OutByDODRe questorNoO ptIn();
        99                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        100                    Asse rt.assertT rue("Valid  Outbound  Doc Query  By DOD Req uestor - n ot opted i n", 
        101                                      response .getResult ().get(0). getDecisio n() ==
        102                                 De cisionType .PERMIT);
        103           }
        104           
        105           @T est
        106           pu blic void  testValidO utboundDoc QueryOutBy DODRequest orWithOptI n() {
        107                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidOutbou ndDocQuery OutByDODRe questorWit hOptIn();
        108                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        109                    Asse rt.assertT rue("Valid  Outbound  Doc Query  By DOD Req uestor - o pted in", 
        110                                      response .getResult ().get(0). getDecisio n() ==
        111                                 De cisionType .PERMIT);
        112           }
        113           
        114           @T est
        115           pu blic void  testValidO utboundDoc QueryOutBy NonDODRequ estorWithO ptIn() {
        116                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidOutbou ndDocQuery OutByNonDO DRequestor WithOptIn( );
        117                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        118                    Asse rt.assertT rue("Valid  Outbound  Doc Query  By Non DOD  Requestor  - opted i n", 
        119                                      response .getResult ().get(0). getDecisio n() ==
        120                                 De cisionType .PERMIT);
        121           }
        122  
        123           @T est
        124           pu blic void  testValidO utboundDoc RetrieveOu tByNonDODR equestorWi thOptIn()  {
        125                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidOutbou ndDocRetri eveOutByNo nDODReques torWithOpt In();
        126                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        127                    Asse rt.assertT rue("Valid  Outbound  Doc Retrie ve By Non  DOD Reques tor - opte d in", 
        128                                      response .getResult ().get(0). getDecisio n() ==
        129                                 De cisionType .PERMIT);
        130           }
        131           
        132           @T est
        133           pu blic void  testValidO utboundPat ientDiscov eryOutByNo nDODReques torWithOpt In() {
        134                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildV alidOutbou ndPatientD iscoveryOu tByNonDODR equestorWi thOptIn();
        135                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        136                    Asse rt.assertT rue("Valid  Outbound  Patient Di scovery By  Non DOD R equestor -  opted in"
        137                                      response .getResult ().get(0). getDecisio n() ==
        138                                 De cisionType .PERMIT);
        139           }
        140           
        141           
        142  
        143           /*  --------- ---------- ----
        144            *  In Valid  Request Ty pes 
        145            *  --------- ---------- ----
        146            * /
        147  
        148  
        149           @T est
        150           pu blic void  testInvali dInboundDo cQueryInBy NonDODRequ estorEmpty OptIn() {
        151                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildI nvalidInbo undDocQuer yInByNonDO DRequestor EmptyOptIn ();
        152                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        153                    Asse rt.assertT rue("InVal id Inbound  Doc Query  By Non DO D Requesto r - not op ted in", 
        154                                      response .getResult ().get(0). getDecisio n() ==
        155                                 De cisionType .DENY);
        156           }
        157           
        158           @T est
        159           pu blic void  testInvali dInboundDo cQueryInBy NonDODRequ estorNoOpt In() {
        160                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildI nvalidInbo undDocQuer yInByNonDO DRequestor NoOptIn();
        161                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        162                    Asse rt.assertT rue("InVal id Inbound  Doc Query  By Non DO D Requesto r - not op ted in", 
        163                                      response .getResult ().get(0). getDecisio n() ==
        164                                 De cisionType .DENY);
        165           }
        166  
        167           
        168  
        169           @T est
        170           //  OptIn/Out  evaluated  only for  PD - Valid ate this
        171           pu blic void  testInvali dOutboundD ocQueryOut ByNonDODRe questorEmp tyOptIn()  {
        172                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildI nvalidOutb oundDocQue ryOutByNon DODRequest orEmptyOpt In();
        173                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        174                    Asse rt.assertT rue("InVal id Outboun d Doc Quer y ?? By No n DOD Requ estor - no t opted in ", 
        175                                      response .getResult ().get(0). getDecisio n() ==
        176                                 De cisionType .PERMIT);
        177           }
        178           //  OptIn/Out  evaluated  only for  PD - Valid ate this
        179           @T est
        180           pu blic void  testInvali dDocQueryO utByNonDOD RequestorN oOptIn() {
        181                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildI nvalidOutb oundDocQue ryOutByNon DODRequest orNoOptIn( );
        182                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        183                    Asse rt.assertT rue("InVal id Outboun d Doc Quer y ?? By No n DOD Requ estor - no t opted in ", 
        184                                      response .getResult ().get(0). getDecisio n() ==
        185                                 De cisionType .PERMIT);
        186           }
        187  
        188           @T est
        189           pu blic void  testInvali dOutboundP atientDisc overyOutBy NonDODRequ estorEmpty OptIn() {
        190                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildI nvalidOutb oundPatien tDiscovery OutByNonDO DRequestor EmptyOptIn ();
        191                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        192                    Asse rt.assertT rue("InVal id Outboun d Patient  Discovery  By Non DOD  Requestor  - not opt ed in", 
        193                                      response .getResult ().get(0). getDecisio n() ==
        194                                 De cisionType .DENY);
        195           }
        196  
        197           /*
        198            *  This test s out the  condition  of a null  input name ly, the re quest.
        199            *  Expected  response i s a Deny
        200            * /
        201           
        202           @T est
        203           pu blic void  testWithNu llRequest( ) {
        204                    //Nu ll Request
        205                    Resp onseType r esponse =  simplePDP. checkPolic y(null);
        206                    Asse rt.assertT rue("Null  request re sulted in  a Deny", 
        207                                      response .getResult ().get(0). getDecisio n() ==
        208                                 De cisionType .DENY);
        209           }
        210  
        211           @T est
        212           pu blic void  testMissin gRequestor ActionInRe quest() {
        213                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildR equestWith outAction( );
        214                    
        215                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        216                    Asse rt.assertT rue("Null  request re sulted in  a Deny", 
        217                                      response .getResult ().get(0). getDecisio n() ==
        218                                 De cisionType .DENY);
        219           }
        220  
        221           @T est
        222           pu blic void  testUnsupp ortedReque storAction InRequest( ) {
        223                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildR equestWith Unsupporte dAction();
        224                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        225                    Asse rt.assertT rue("Null  request re sulted in  a Deny", 
        226                                      response .getResult ().get(0). getDecisio n() ==
        227                                 De cisionType .DENY);
        228           }
        229                    
        230           @T est
        231           pu blic void  testMissin gRequestor HomeCommun ityIdInReq uest() {
        232                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildW ithoutHCID ();
        233                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        234                    Asse rt.assertT rue("Null  request re sulted in  a Deny", 
        235                                      response .getResult ().get(0). getDecisio n() ==
        236                                 De cisionType .DENY);
        237           }
        238           
        239           @T est
        240           pu blic void  testMissin gRequestor PatientIdI nRequest()  {
        241                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildW ithoutPati entId();
        242                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        243                    Asse rt.assertT rue("Null  request re sulted in  a Deny", 
        244                                      response .getResult ().get(0). getDecisio n() ==
        245                                 De cisionType .DENY);
        246           }
        247           
        248           @T est
        249           pu blic void  testMissin gPOU() {
        250                    Requ estType re quest = Sa mpleXACMLR equestBuil der.buildR equestWith MissingPOU ();
        251                    Resp onseType r esponse =  simplePDP. checkPolic y(request) ;
        252                    Asse rt.assertT rue("Null  request re sulted in  a Deny", 
        253                                      response .getResult ().get(0). getDecisio n() ==
        254                                 De cisionType .DENY);
        255           }
        256  
        257   }