public override void CallingColumnExistsReturnsFalseIfColumnDoesNotExistWithSchema() { using (var table = new Db2TestTable(Processor, "TstSchma", "ID INT")) { Processor.ColumnExists("TstSchma", table.Name, "DoesNotExist").ShouldBeFalse(); } }
public override void CallingColumnExistsCanAcceptTableNameWithSingleQuote() { using (var table = new Db2TestTable("Test'Table", Processor, null, "ID INT")) { Processor.ColumnExists(null, table.Name, "ID").ShouldBeTrue(); } }
public override void CallingColumnExistsReturnsFalseIfColumnDoesNotExist() { using (var table = new Db2TestTable(Processor, null, "ID INT")) { Processor.ColumnExists(null, table.Name, "DoesNotExist").ShouldBeFalse(); } }
public override void CallingColumnExistsReturnsTrueIfColumnExists() { using (var table = new Db2TestTable(Processor, null, "ID INT")) { Processor.ColumnExists(null, table.Name, "ID").ShouldBeTrue(); } }
public override void CallingSchemaExistsReturnsTrueIfSchemaExists() { using (var table = new Db2TestTable(Processor, "TstSchma", "ID INT")) { Processor.SchemaExists("TstSchma").ShouldBeTrue(); } }
public override void CallingTableExistsReturnsTrueIfTableExistsWithSchema() { using (var table = new Db2TestTable(Processor, "TstSchma", "ID INT")) { Processor.TableExists("TstSchma", table.Name).ShouldBeTrue(); } }
public void CallingTableExistsReturnsFalseIfTableExistsInDifferentSchema() { using (var table = new Db2TestTable(Processor, "TstSchma", "ID INT")) { Processor.TableExists("DNE", table.Name).ShouldBeFalse(); } }
public override void CallingConstraintExistsReturnsTrueIfConstraintExists() { using (var table = new Db2TestTable(Processor, null, "ID INT")) { table.WithUniqueConstraintOn("ID", "C1"); Processor.ConstraintExists(null, table.Name, "C1").ShouldBeTrue(); } }
public override void CallingConstraintExistsCanAcceptTableNameWithSingleQuote() { using (var table = new Db2TestTable("Test'Table", Processor, null, "ID INT")) { table.WithUniqueConstraintOn("ID", "C'1"); Processor.ConstraintExists(null, table.Name, "C'1").ShouldBeTrue(); } }
public void CallingConstraintExistsReturnsFalseIfConstraintExistsInDifferentSchema() { using (var table = new Db2TestTable(Processor, "TstSchma", "ID INT")) { table.WithUniqueConstraintOn("ID", "c1"); Processor.ConstraintExists("DNE", table.Name, "c1").ShouldBeFalse(); } }
public override void CallingConstraintExistsReturnsTrueIfConstraintExistsWithSchema() { using (var table = new Db2TestTable(Processor, "TstSchma", "ID INT NOT NULL")) { table.WithUniqueConstraintOn("ID", "C1"); Processor.ConstraintExists("TstSchma", table.Name, "C1").ShouldBeTrue(); } }
public override void CallingIndexExistsReturnsTrueIfIndexExists() { using (var table = new Db2TestTable(Processor, null, "ID INT")) { table.WithIndexOn("ID", "UI_id"); Processor.IndexExists(null, table.Name, "UI_id").ShouldBeTrue(); } }
public override void CallingIndexExistsCanAcceptTableNameWithSingleQuote() { using (var table = new Db2TestTable("Test'Table", Processor, null, "ID INT")) { table.WithIndexOn("ID", "UI_id"); Processor.IndexExists(null, table.Name, "UI_id").ShouldBeTrue(); } }
public override void CallingColumnExistsCanAcceptColumnNameWithSingleQuote() { var columnName = Quoter.Quote("I'D") + " INT"; using (var table = new Db2TestTable(Processor, null, columnName)) { Processor.ColumnExists(null, table.Name, "I'D").ShouldBeTrue(); } }