Skip to content

Instantly share code, notes, and snippets.

@jharmn
Created January 13, 2013 01:59
Show Gist options
  • Select an option

  • Save jharmn/4521805 to your computer and use it in GitHub Desktop.

Select an option

Save jharmn/4521805 to your computer and use it in GitHub Desktop.
[Then(@"it should have the field ""(.*)"" containing the value ""(.*)""")]
public void ThenItShouldContainTheFieldContainingTheValue(string field, string value)
{
if (response != null)
{
JValue val = (JValue)this.response.GetValue(field);
string valStr = val.Value().Trim();
Assert.IsNotNull(valStr);
Assert.AreEqual(valStr, value.Trim());
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment