Esempio n. 1
0
        public void TELExample8Test01()
        {
            var tel      = new TEL("tel:+190555525485");
            var weekdays = new PIVL <TS>(
                new IVL <TS>(DateTime.Parse("08-15-2011"), DateTime.Parse("08-19-2011")),
                new PQ(-1, "wk")
                );
            var nineToFive = new PIVL <TS>(
                // given low, high, and inaccurate width
                new IVL <TS>(DateTime.Parse("08-15-2011 09:00 AM"),
                             DateTime.Parse("08-19-2011 05:00 PM")),
                new PQ(-1, "d")
                )
            {
                Operator = SetOperator.Intersect
            };

            tel.UseablePeriod = new GTS(new SXPR <TS>(
                                            new SXCM <TS>[] {
                weekdays,
                nineToFive
            }
                                            ));
            tel.Use = null;
            Assert.IsTrue(tel.Validate());
        }
Esempio n. 2
0
        public void TELNullTest()
        {
            TEL tel = new TEL();

            tel.Value      = null;
            tel.NullFlavor = null;
            Assert.IsFalse(tel.Validate());
        }
Esempio n. 3
0
        public void TELNullFlavorTest()
        {
            TEL tel = new TEL();

            tel.Value      = null;
            tel.NullFlavor = NullFlavor.NotAsked;
            Assert.IsTrue(tel.Validate());
        }
Esempio n. 4
0
        public void TELValidValueTest()
        {
            TEL tel = new TEL();

            tel.Value      = "mailto:[email protected]";
            tel.NullFlavor = null;
            Assert.IsTrue(tel.Validate());
        }
Esempio n. 5
0
        public void TELValueNullFlavorTest()
        {
            TEL tel = new TEL();

            tel.Value      = "*****@*****.**";
            tel.NullFlavor = NullFlavor.NotApplicable;
            Assert.IsFalse(tel.Validate());
        }
Esempio n. 6
0
        public void TELConstructionTest2()
        {
            TEL phone = new TEL("tel:+13335551212;postd=2345",
                                new CS <TelecommunicationAddressUse>[] {
                TelecommunicationAddressUse.WorkPlace,
                TelecommunicationAddressUse.Direct
            }
                                );

            phone.NullFlavor = NullFlavor.Unknown;
            Assert.IsFalse(phone.Validate());
        }
Esempio n. 7
0
        public void TELExample7Test03()
        {
            var tel = new TEL("",
                              new CS <TelecommunicationAddressUse>[] {
                TelecommunicationAddressUse.WorkPlace,
                TelecommunicationAddressUse.Direct
            }
                              );

            tel.Value = "tel:+13335551212;postd=2345";
            tel.Use   = null;
            Assert.IsTrue(tel.Validate());
        }
Esempio n. 8
0
        public void TELExample7Test01()
        {
            var tel = new TEL("tel:+13335551212;postd=2345",
                              new CS <TelecommunicationAddressUse>[] {
                TelecommunicationAddressUse.WorkPlace,
                TelecommunicationAddressUse.Direct
            }
                              );

            tel.Capabilities  = null;
            tel.UseablePeriod = null;
            Assert.IsTrue(tel.Validate());
        }
Esempio n. 9
0
 public void TELConstructionTest1()
 {
     // 
     TEL phone = new TEL("tel:+13335551212;postd=2345",
         new CS<TelecommunicationAddressUse>[]{
             TelecommunicationAddressUse.WorkPlace,
             TelecommunicationAddressUse.Direct
     }
     );
     phone.NullFlavor = null;
     Assert.IsTrue(phone.Validate());
 }
Esempio n. 10
0
        public void TELExample8Test02()
        {
            var tel = new TEL("tel:+190555525485");
            var weekdays = new PIVL<TS>(
                new IVL<TS>(DateTime.Parse("08-15-2011"), DateTime.Parse("08-19-2011")),
                new PQ(-1, "wk")
            );

            var nineToFive = new PIVL<TS>(
                // given low, high, and inaccurate width
                new IVL<TS>(DateTime.Parse("08-15-2011 09:00 AM"),
                    DateTime.Parse("08-19-2011 05:00 PM")),
                    new PQ(-1, "d")
                )
            {
                Operator = SetOperator.Intersect
            };
            tel.UseablePeriod = null;
            tel.Use = null;
            Assert.IsTrue(tel.Validate());
        }
Esempio n. 11
0
 public void TELExample7Test03()
 {
     var tel = new TEL("",
         new CS<TelecommunicationAddressUse>[]{
             TelecommunicationAddressUse.WorkPlace,
             TelecommunicationAddressUse.Direct
         }
     );
     tel.Value = "tel:+13335551212;postd=2345";
     tel.Use = null;
     Assert.IsTrue(tel.Validate());
 }
Esempio n. 12
0
 public void TELExample7Test01()
 {
     var tel = new TEL("tel:+13335551212;postd=2345",
         new CS<TelecommunicationAddressUse>[]{
             TelecommunicationAddressUse.WorkPlace,
             TelecommunicationAddressUse.Direct
         }
     );
     tel.Capabilities = null;
     tel.UseablePeriod = null;
     Assert.IsTrue(tel.Validate());
 }
Esempio n. 13
0
 public void TELNullTest()
 {
     TEL tel = new TEL();
     tel.Value = null;
     tel.NullFlavor = null;
     Assert.IsFalse(tel.Validate());
 }
Esempio n. 14
0
 public void TELNullFlavorTest()
 {
     TEL tel = new TEL();
     tel.Value = null;
     tel.NullFlavor = NullFlavor.NotAsked;
     Assert.IsTrue(tel.Validate());
 }
Esempio n. 15
0
 public void TELValidValueTest()
 {
     TEL tel = new TEL();
     tel.Value = "mailto:[email protected]";
     tel.NullFlavor = null;
     Assert.IsTrue(tel.Validate());
 }
Esempio n. 16
0
 public void TELValueNullFlavorTest()
 {
     TEL tel = new TEL();
     tel.Value = "*****@*****.**";
     tel.NullFlavor = NullFlavor.NotApplicable;
     Assert.IsFalse(tel.Validate());
 }