Skip to content

Instantly share code, notes, and snippets.

@SzymonPobiega
Created June 15, 2011 13:31
Show Gist options
  • Save SzymonPobiega/1027094 to your computer and use it in GitHub Desktop.
Save SzymonPobiega/1027094 to your computer and use it in GitHub Desktop.
Small internal DSL in unit tests
[TestMethod]
public void It_uses_more_specific_rule_if_rule_and_information_is_present()
{
Given(new ProductType("air", null, ProductCategory.AirOnly),
new ProductType("air", "someSpecialWeirdProduct", ProductCategory.LandOnly))
.ItMaps(new ProductReference("air", "someSpecialWeirdProduct"))
.To(ProductCategory.LandOnly);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment