Пример #1
0
 public override void CallingConstraintExistsReturnsFalseIfConstraintDoesNotExist()
 {
     using (var table = new HanaTestTable(this.Processor, null, "id int"))
     {
         table.WithUniqueConstraintOn("ID");
         this.Processor.ConstraintExists(null, table.Name, "DoesNotExist").ShouldBeFalse();
     }
 }
Пример #2
0
 public override void CallingConstraintExistsCanAcceptTableNameWithSingleQuote()
 {
     using (var table = new HanaTestTable("Test'Table", Processor, null, "id int"))
     {
         table.WithUniqueConstraintOn("ID");
         this.Processor.ConstraintExists(null, table.Name, "UC_id").ShouldBeTrue();
     }
 }
Пример #3
0
        public override void CallingConstraintExistsReturnsFalseIfConstraintDoesNotExistWithSchema()
        {
            Assert.Ignore("HANA does not support schema like us know schema in hana is a database name");

            using (var table = new HanaTestTable(Processor, "schemaName", "id int"))
            {
                table.WithUniqueConstraintOn("ID");
                this.Processor.ConstraintExists("schemaName", table.Name, "DoesNotExist").ShouldBeFalse();
            }
        }
Пример #4
0
 public override void CallingConstraintExistsReturnsTrueIfConstraintExists()
 {
     using (var table = new HanaTestTable(Processor, null, "id int"))
     {
         table.WithUniqueConstraintOn("ID");
         this.Processor.ConstraintExists(null, table.Name, "UC_id").ShouldBeTrue();
     }
 }