Example #1
0
        public void ContainsMiss()
        {
            var whiteListManager = new WhiteListManager();

            var result = whiteListManager.IsContained(a => a.ResourceName == "TestNotFound");

            Assert.IsFalse(result);
        }
Example #2
0
        public void GetNullItem()
        {
            var whiteListManager = new WhiteListManager();

            var result = whiteListManager.GetItem(a => a.ID == 0);

            Assert.IsNull(result);
        }
Example #3
0
        public void GetActualItem()
        {
            var whiteListManager = new WhiteListManager();

            var item = new WhiteListObject
            {
                ResourceName = "Test"
            };

            var resultID = whiteListManager.AddItem(item);

            var result = whiteListManager.GetItem(a => a.ID == resultID);

            Assert.IsNotNull(result);
        }
Example #4
0
        public void ContainsNull()
        {
            var whiteListManager = new WhiteListManager();

            Assert.IsFalse(whiteListManager.IsContained(a => a == null));
        }