public void ShouldReturnEmptyWhenValidCurrencyAndNumeral() { // arrange var textToTest = "test is V"; var currencies = new Dictionary <string, string>(); var rule = new CurrencyAssignmentParsingRule(); // act var result = rule.Process(textToTest, currencies, null); // assert result.ShouldBe(string.Empty); currencies.ShouldContainKeyAndValue("test", "V"); }
public void ShouldReturnErrorMessageWhenNoValidNumeral() { // arrange var textToTest = "test is Z"; var currencies = new Dictionary <string, string> { { "test", "X" } }; var rule = new CurrencyAssignmentParsingRule(); // act var result = rule.Process(textToTest, currencies, null); // assert result.ShouldBe(Program.ERROR_MESSAGE); }