//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Before public void setUp() public virtual void SetUp() { // begin HTTP.Response begin = _http.POST("db/data/transaction"); assertThat(begin.Status(), equalTo(201)); AssertHasTxLocation(begin); try { _commitResource = begin.StringFromContent("commit"); } catch (JsonParseException e) { fail("Exception caught when setting up test: " + e.Message); } assertThat(_commitResource, equalTo(begin.Location() + "/commit")); }
private void AssertHasTxLocation(HTTP.Response begin) { assertThat(begin.Location(), matches("http://localhost:\\d+/db/data/transaction/\\d+")); }