private void Step_30_TestFindByQuery_Generated()
{
using (TransactionManager tm = CreateTransaction())
{
//Insert Mock Instance
EmployeePayHistory mock = CreateMockInstance(tm);
bool result = DataRepository.EmployeePayHistoryProvider.Insert(tm, mock);
Assert.IsTrue(result, "Could Not Test FindByQuery, Insert Failed");
EmployeePayHistoryQuery query = new EmployeePayHistoryQuery();
query.AppendEquals(EmployeePayHistoryColumn.EmployeeId, mock.EmployeeId.ToString());
query.AppendEquals(EmployeePayHistoryColumn.RateChangeDate, mock.RateChangeDate.ToString());
query.AppendEquals(EmployeePayHistoryColumn.Rate, mock.Rate.ToString());
query.AppendEquals(EmployeePayHistoryColumn.PayFrequency, mock.PayFrequency.ToString());
query.AppendEquals(EmployeePayHistoryColumn.ModifiedDate, mock.ModifiedDate.ToString());
TList<EmployeePayHistory> results = DataRepository.EmployeePayHistoryProvider.Find(tm, query);
Assert.IsTrue(results.Count == 1, "Find is not working correctly. Failed to find the mock instance");
}
}