Ejemplo n.º 1
0
        public void TakeFilterThrowsExceptionIfStringIsLessThanRequestedChars()
        {
            var filter = new TakeFilter(4);

            Assert.Throws <InvalidOperationException>(() => filter.Apply("Foo"));
        }
Ejemplo n.º 2
0
        public void TakeFilterTakesTheFirstNCharacters()
        {
            var filter = new TakeFilter(1);

            Assert.Equal("F", filter.Apply("Foo"));
        }