Skip to content

Commit

Permalink
Add test case for issue 178
Browse files Browse the repository at this point in the history
  • Loading branch information
peej committed Feb 6, 2014
1 parent 7507643 commit 7589f49
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
16 changes: 16 additions & 0 deletions features/bootstrap/FeatureContext.php
Expand Up @@ -537,4 +537,20 @@ public function theApplicationDoesNotHaveAResourceForClass($className)
throw new Exception('Application has a resource for class "' . $className . '"');
}
}
/**
* @Given /^a response object$/
*/
public function aResponseObject()
{
$this->response = new Response;
}

/**
* @When /^set the response header of "([^"]*)" to "([^"]*)"$/
*/
public function setTheResponseHeaderOfTo($name, $value)
{
$this->response->$name = $value;
}

}
9 changes: 9 additions & 0 deletions features/issue178.feature
@@ -0,0 +1,9 @@
Feature: Issue 178
In order to make sure issue #178 (https://github.com/peej/tonic/issues/178) is fixed
As a Tonic developer
I want to test the problems in the issue

Scenario:
Given a response object
When set the response header of "Content-MD5" to "blah"
Then the response should have the header "Content-MD5" with the value "blah"

0 comments on commit 7589f49

Please sign in to comment.