Changeset 471 in tmcsimulator for trunk/test/tmcsim
- Timestamp:
- 07/29/2019 01:36:40 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/tmcsim/cadsimulator/CoordinatorTest.java
r465 r471 30 30 public void testWriteToCADLog() throws RemoteException 31 31 { 32 System.out.println(" write to CAD log");32 System.out.println("testing write to CAD log"); 33 33 Coordinator coord = new Coordinator(null,"",""); 34 34 Vector<Incident> incList = new Vector<Incident>(); … … 51 51 List<String> result = coord.getSortedComments(incList); 52 52 assertTrue(result != null); 53 assert (result.get(0).startsWith("00")); 54 assert (result.get(1).startsWith("01")); 55 assert (result.get(2).startsWith("03")); 56 assert (result.get(3).startsWith("10")); 53 assertTrue (result.get(0).startsWith("00")); 54 assertTrue (result.get(1).startsWith("01")); 55 assertTrue (result.get(2).startsWith("03")); 56 assertTrue (result.get(3).startsWith("10")); 57 } 58 public void testBadDataWriteToCADLog() throws RemoteException 59 { 60 System.out.println("test int conversion in write to CAD log"); 61 Coordinator coord = new Coordinator(null,"",""); 62 Vector<Incident> incList = new Vector<Incident>(); 63 Incident inci1 = new Incident(201, "Alpha", 10L); 64 Incident inci2 = new Incident(209, "Bravo", 20L); 65 Incident inci3 = new Incident(209, "Charly", 20L); 66 String[] fields1 = {"date","01:01:01","JHD","?","two"}; 67 String[] fields2 = {"date","99999999209","JHD","?","one"}; 68 String[] fields3 = {"date","INVALID","JHD","?","one"}; 69 inci1.addToCommentsNotesTable(fields1); 70 inci2.addToCommentsNotesTable(fields2); 71 inci2.addToCommentsNotesTable(fields3); 72 incList.add(inci1); 73 incList.add(inci2); 74 incList.add(inci3); 75 List<String> result = coord.getSortedComments(incList); 76 assertTrue(result != null); 77 assertTrue (result.get(0).startsWith("INVALID")); 78 assertTrue (result.get(1).startsWith("01")); 79 assertTrue (result.get(2).startsWith("99")); 57 80 } 58 81 }
Note: See TracChangeset
for help on using the changeset viewer.
