Example #1
0
        public void TestIdentifyConstructor()
        {
            Identify ident = new Identify(new string [] { "id1", "id2" });

            Assert.AreEqual("id1", ident.FirstId, "Identify constructor should add idents");
            Assert.AreEqual(2, ident.Count(), "Should have 2 ids inserted");
        }
Example #2
0
        public void TestAddIdentifier()
        {
            Identify ident = new Identify(new string [] {});

            ident.AddIdentifier("ID1");

            Assert.AreEqual("id1", ident.FirstId, "Should turn id to LowerCase before inserting");
        }
Example #3
0
        public void TestCount()
        {
            Identify ident = new Identify(new string [] { "id1", "id2" });

            Assert.AreEqual(2, ident.Count(), "Should have 2 ids inserted");
        }
Example #4
0
        public void TestCaseSensitive()
        {
            Identify ident = new Identify(new string [] { "id1", "id2" });

            Assert.AreEqual(true, ident.AreYou("ID1"), "Should find id is in list");
        }
Example #5
0
        public void TestNotAreYou()
        {
            Identify ident = new Identify(new string [] { "id1", "id2" });

            Assert.AreEqual(false, ident.AreYou("id5"), "Should find id is not in list");
        }
Example #6
0
        public void TestFirstId()
        {
            Identify ident = new Identify(new string [] {});

            Assert.AreEqual("", ident.FirstId, "Should have empty list");
        }