Пример #1
0
 public void BPageWithInvalidName_IsNotUpdateValid()
 {
     //Name is assigned a string of length 17
     BPage valid = new BPage {
         Name = "12345678901234567",
         Title = "Valid",
         Icon_Url = "Valid",
         Url = "Valid"
     };
     Assert.IsFalse(valid.UpdateValid());
 }
Пример #2
0
 public void BPageWithNullMembers_IsUpdateValid()
 {
     BPage valid = new BPage {
         Name = null,
         Title = null,
         Icon_Url = null,
         Url = null
     };
     Assert.IsTrue(valid.UpdateValid());
 }
Пример #3
0
 public void BPageWithValidMembers_IsUpdateValid()
 {
     BPage valid = new BPage {
         Name = "Valid",
         Title = "Valid",
         Icon_Url = "Valid",
         Url = "Valid"
     };
     Assert.IsTrue(valid.UpdateValid());
 }
Пример #4
0
 public void BPageWithInvalidUrl_IsNotUpdateValid()
 {
     //Icon Url is assigned a string of length 1100
     BPage valid = new BPage {
         Name = "Valid",
         Title = "Valid",
         Icon_Url = "Valid",
         Url = @"1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
                   1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890"
     };
     Assert.IsFalse(valid.UpdateValid());
 }