Esempio n. 1
0
        public void Equals(string name1, string name2, bool expected)
        {
            var field1 = CecilFieldTest.GetField(name1);
            var field2 = CecilFieldTest.GetField(name2);

            Assert.That(field1.Equals(field2), Is.EqualTo(expected));
            Assert.That(field1 == field2, Is.EqualTo(expected));
            Assert.That(field1 != field2, Is.EqualTo(!expected));
        }
Esempio n. 2
0
 public void Visibility(string name, Visibility expected)
 {
     Assert.That(CecilFieldTest.GetField(name).Visibility, Is.EqualTo(expected));
 }
Esempio n. 3
0
 public void Type(string name, string expected)
 {
     Assert.That(CecilFieldTest.GetField(name).Type.Name, Is.EqualTo(expected));
 }
Esempio n. 4
0
 public void Parent(string name, string expected)
 {
     Assert.That(CecilFieldTest.GetField(name).Parent.Name, Is.EqualTo(expected));
 }
Esempio n. 5
0
 public void Name(string name)
 {
     Assert.That(CecilFieldTest.GetField(name).Name, Is.EqualTo(name));
 }
Esempio n. 6
0
 public void Binding(string name, Binding expected)
 {
     Assert.That(CecilFieldTest.GetField(name).Binding, Is.EqualTo(expected));
 }
Esempio n. 7
0
        public void Attributes(string name, string expected)
        {
            var attributes = string.Join(",", CecilFieldTest.GetField(name).Attributes.Select(a => a.Type.Name));

            Assert.That(attributes, Is.EqualTo(expected));
        }