Exemple #1
0
        public void CheckIfClearExceptionsWorkCorrectly()
        {
            var hashList = new DataStructures.HashingListDictionary <string, string>(10);

            hashList.MakeReadOnly();
            Assert.Throws <NotSupportedException>(() => hashList.Clear());
        }
Exemple #2
0
        public void CheckIfThisExceptionsWorkCorrectly2()
        {
            var hashList = new DataStructures.HashingListDictionary <string, string>(10);

            hashList.Add("1", "Ana");
            hashList.MakeReadOnly();
            Assert.Throws <NotSupportedException>(() => hashList["string"] = "Banana");
        }