public void WriteRecordWithStudentsTest()
 {
     VisitorTableController target = new VisitorTableController();
     Dictionary<string, object> record = new Dictionary<string,object>();
     record.Add("ID", studId);
     record.Add("Name", studName);
     record.Add("ClassID", classId);
     record.Add("PIN", pin);
     record.Add("TimeIn", timeIn);
     record.Add("DroppedBy", visId);
     record.Add("TimeOut", timeOut);
     record.Add("PickedUp", visId);
     target.WriteRecordWithStudents(record);
     Assert.IsTrue(recordCompare( record, target.GetRecordWithStudents(studId, today)));
 }
 public void GetStudentReportTest()
 {
     VisitorTableController target = new VisitorTableController(); // TODO: Initialize to an appropriate value
     DateTime start = new DateTime(today.Year, today.Month, today.Day - 2);
     DateTime end = new DateTime(today.Year, today.Month, today.Day - 1);
     List<Dictionary<string, object>> expected = new List<Dictionary<string, object>>();
     expected.Add(target.GetRecordWithStudents(visId, start));
     expected.Add(target.GetRecordWithStudents(visId, end));
     List<Dictionary<string, object>> actual;
     actual = target.GetStudentReport(start, end);
     Assert.AreEqual(actual.Count, expected.Count);
     foreach (Dictionary<string, object> rec in expected)
     {
         Assert.IsTrue(recordCompare(rec, actual[expected.IndexOf(rec)]));
     }
 }