package Ġorg . simple . clin ic . summary . next appointment Ċ Ċ import Ġcom . spotify . mob ius . test . First Matchers . has Effects Ċ import Ġcom . spotify . mob ius . test . First Matchers . has Model Ċ import Ġcom . spotify . mob ius . test . First Matchers . has No Effects Ċ import Ġcom . spotify . mob ius . test . Init Spec Ċ import Ġcom . spotify . mob ius . test . Init Spec . assertThat First Ċ import Ġorg . junit . Test Ċ import Ġorg . simple . clin ic . TestData Ċ import Ġjava . time . LocalDate Ċ import Ġjava . util . UUID Ċ Ċ class ĠNext Appointment Init Test Ġ{ ĊĊĠ Ġprivate Ġval Ġpatient Uuid Ġ= ĠUUID . fromString (" d 7 da ec 3 4 - 2 a 9 c - 4 4 d 1 - 9 8 9 2 - c 3 8 d 8 2 af 1 2 4 3 ") ĊĠ Ġprivate Ġval Ġdefault Model Ġ= ĠNext Appointment Model . default ( ĊĠĠĠĠĠ Ġpatient Uuid Ġ= Ġpatient Uuid , ĊĠĠĠĠĠ Ġcurrent Date Ġ= ĠLocalDate . parse (" 2 0 1 8 - 0 1 - 0 1 ") ĊĠ Ġ) ĊĠ Ġprivate Ġval Ġinit Spec Ġ= ĠInit Spec ( Next Appointment Init ()) ĊĊĠ Ġ@ Test ĊĠ Ġfun Ġ` when Ġview Ġis Ġcreated , Ġthen Ġload Ġappointment `() Ġ{ ĊĠĠĠ Ġinit Spec ĊĠĠĠĠĠĠĠ Ġ. when Init ( default Model ) ĊĠĠĠĠĠĠĠ Ġ. then ( assertThat First ( ĊĠĠĠĠĠĠĠĠĠĠĠ Ġhas Model ( default Model ), ĊĠĠĠĠĠĠĠĠĠĠĠ Ġhas Effects ( Load Next Appointment Patient Profile ( patient Uuid Ġ= Ġpatient Uuid )) ĊĠĠĠĠĠĠĠ Ġ)) ĊĠ Ġ} ĊĊĠ Ġ@ Test ĊĠ Ġfun Ġ` when Ġview Ġis Ġrestored , Ġthen Ġdon 't Ġload Ġappointment `() Ġ{ ĊĠĠĠ Ġval Ġfacility Uuid Ġ= ĠUUID . fromString (" 3 ea ab 5 df - 9 4 7 9 - 4 8 a 6 - acb 6 - 3 cd 4 b 9 f 1 2 3 2 6 ") ĊĠĠĠ Ġval Ġpatient Ġ= ĠTest Data . patient ( ĊĠĠĠĠĠĠĠ Ġuuid Ġ= Ġpatient Uuid , ĊĠĠĠĠĠĠĠ ĠfullName Ġ= Ġ" R ame sh " ĊĠĠĠ Ġ) ĊĊĠĠĠ Ġval Ġfacility Ġ= ĠTest Data . facility ( ĊĠĠĠĠĠĠĠ Ġuuid Ġ= Ġfacility Uuid , ĊĠĠĠĠĠĠĠ Ġname Ġ= Ġ" PH C ĠOb vious " ĊĠĠĠ Ġ) ĊĊĠĠĠ Ġval Ġappointment Ġ= ĠTest Data . appointment ( ĊĠĠĠĠĠĠĠ Ġuuid Ġ= ĠUUID . fromString (" fce 2 5 9 b 8 - 7 9 3 a - 4 e 9 2 - 8 a 2 7 - 4 2 3 2 5 8 be 3 bf 7 "), ĊĠĠĠĠĠĠĠ Ġpatient Uuid Ġ= Ġpatient Uuid ĊĠĠĠ Ġ) ĊĊĠĠĠ Ġval Ġnext Appointment Patient Profile Ġ= ĠNext Appointment Patient Profile ( appointment , Ġpatient , Ġfacility ) ĊĊĠĠĠ Ġval Ġappointment Loaded Model Ġ= Ġdefault Model . next Appointment Patient Profile Loaded ( next Appointment Patient Profile ) ĊĊĠĠĠ Ġinit Spec ĊĠĠĠĠĠĠĠ Ġ. when Init ( appointment Loaded Model ) ĊĠĠĠĠĠĠĠ Ġ. then ( assertThat First ( ĊĠĠĠĠĠĠĠĠĠĠĠ Ġhas Model ( appointment Loaded Model ), ĊĠĠĠĠĠĠĠĠĠĠĠ Ġhas No Effects () ĊĠĠĠĠĠĠĠ Ġ)) ĊĠ Ġ} Ċ } Ċ