Bladeren bron

CensusEntry age and where born added to Bootstrap

Andrew Grant 5 maanden geleden
bovenliggende
commit
be39ca9ba0

+ 2 - 2
docs/additions.txt

@@ -6,8 +6,8 @@
 5: Command getter and setter in Command Test
 6: Converter
 7: Converter Test
-8: Bootstrap (use random string)
-9: Bootstrap Test (tst for not null)
+8: Bootstrap (use personal details)
+9: Bootstrap
 10: Validator
 11: Validator Test
 13: Modify the form

+ 5 - 0
src/main/java/scot/carricksoftware/grants/bootstrap/DataLoadCensus.java

@@ -23,6 +23,8 @@ import scot.carricksoftware.grants.services.census.CensusService;
 import scot.carricksoftware.grants.services.people.PersonService;
 import scot.carricksoftware.grants.services.places.places.PlaceService;
 
+
+
 import java.time.LocalDate;
 
 @Component
@@ -73,6 +75,9 @@ public class DataLoadCensus {
         censusEntryCommand.setCondition(CensusEntryCondition.MARRIED);
         censusEntryCommand.setGaelic(CensusEntryGaelic.GAELIC);
         censusEntryCommand.setWorker(CensusEntryWorker.WORKER);
+        censusEntryCommand.setAge("72");
+        censusEntryCommand.setWhereBorn("Edinburgh");
+
         censusEntryService.saveCensusEntryCommand(censusEntryCommand);
     }
 

+ 2 - 0
src/test/java/scot/carricksoftware/grants/bootstrap/DataLoadCensusTest.java

@@ -87,6 +87,8 @@ public class DataLoadCensusTest {
         assertEquals(CensusEntryCondition.MARRIED, captor.getValue().getCondition());
         assertEquals(CensusEntryGaelic.GAELIC, captor.getValue().getGaelic());
         assertEquals(CensusEntryWorker.WORKER, captor.getValue().getWorker());
+        assertEquals("72", captor.getValue().getAge());
+        assertEquals("Edinburgh", captor.getValue().getWhereBorn());
     }