示例#1
0
        public static void Keyword_GivenNullEmptyOrWhiteSpace_ThrowsArgNullException()
        {
            FabulousText text = string.Empty;

            Assert.Multiple(() =>
            {
                Assert.Throws <ArgumentNullException>(() => text.Keyword(null));
                Assert.Throws <ArgumentNullException>(() => text.Keyword(string.Empty));
                Assert.Throws <ArgumentNullException>(() => text.Keyword("   "));
            });
        }
示例#2
0
        public static void Keyword_GivenInvalidKeywordEnum_ThrowsArgNullException()
        {
            FabulousText text = string.Empty;

            const ColorKeyword keyword = (ColorKeyword)293048;

            Assert.Throws <ArgumentException>(() => text.Keyword(keyword));
        }