public void AddEntityTest() { var user = new User { Name = "Dennis Predovnik", CreatedDateTime = DateTime.Now, }; var q1 = new Query { CreatedDateTime = DateTime.Now, DbType = EnumDatabase.Oracle, Description = "Query - Simple from Test", DisplayOnHomeScreen = true, Name = "RPO - Simple Query", Text = "SELECT * from Entity", Owner = user, ParameterCount = 0, Published = true }; ExecuteCommandWithoutResult(locator => { locator.Save(user); locator.Save(q1); }); ExecuteCommandWithoutResult(locator => CountEntities(locator, 3)); }
private Query AddDefaultProperties(Query newQuery,User owner) { newQuery.CreatedDateTime = DateTime.Now; newQuery.Owner = owner; newQuery.Published = true; newQuery.DbType = EnumDatabase.Oracle; return newQuery; }
private static void Create2Users(IRepositoryLocator locator) { var user = new User() { Name = "Chris Ranasinghe", }; locator.Save(user); var user2 = new User() { Name = "Anil De Silva", }; locator.Save(user2); }