AppHarbor.Tests.TypeNameMatcherTest.ShouldThrowWhenNoTypesMatches C# (CSharp) Method

ShouldThrowWhenNoTypesMatches() private method

private ShouldThrowWhenNoTypesMatches ( string commandName ) : void
commandName string
return void
        public void ShouldThrowWhenNoTypesMatches(string commandName)
        {
            var matcher = new TypeNameMatcher<IFoo>(new Type[] { FooCommandType });

            var exception = Assert.Throws<ArgumentException>(() => matcher.GetMatchedType(commandName));
            Assert.Equal(string.Format("The command \"{0}\" is invalid.", commandName), exception.Message);
        }