Beispiel #1
0
        public void StructInheritingFromInterfacePositive2()
        {
            var empty = new EmptyIntIndexable();
            int x     = empty.Count;

            Assert.AreEqual(0, x);
        }
Beispiel #2
0
 public void StructInheritingFromInterfaceNegative2()
 {
   var empty = new EmptyIntIndexable();
   try
   {
     int x = empty[0];
     throw new Exception();
   }
   catch (TestRewriterMethods.PreconditionException p)
   {
     Assert.Equal("index < this.Count", p.Condition);
   }
 }
Beispiel #3
0
        public void StructInheritingFromInterfaceNegative2()
        {
            var empty = new EmptyIntIndexable();

            try
            {
                int x = empty[0];
                throw new Exception();
            }
            catch (TestRewriterMethods.PreconditionException p)
            {
                Assert.AreEqual("index < this.Count", p.Condition);
            }
        }
Beispiel #4
0
 public void StructInheritingFromInterfacePositive2()
 {
   var empty = new EmptyIntIndexable();
   int x = empty.Count;
   Assert.Equal(0, x);
 }