프로퍼티 | 타입 | 설명 | |
---|---|---|---|
$client | Guzzle\Http\Client | Guzzle client used to make requests against the httpd | |
$queryParams | array | Query parameters for the request | |
$requestBody | string | Optional request body to add to the request | |
$requestHeaders | array | Headers for the request | |
$responses | Guzzle\Http\Message\Response[] | The current response objects used by the client (populated when the request is sent) |
메소드 | 설명 | |
---|---|---|
__construct ( array $parameters ) | Class constructor | |
appendQueryStringParameter ( $queryParam, $value ) | ||
assertEmptyResponseBody ( ) | ||
assertEqualResponseHeaders ( Behat\Gherkin\Node\PyStringNode $list ) | ||
assertExistingHeaders ( Behat\Gherkin\Node\PyStringNode $list ) | ||
assertHeaderDoesNotExist ( $header ) | ||
assertHeaderNotSameForPreviousRequests ( $header ) | ||
assertMaxAge ( $seconds ) | ||
assertMissingHeaders ( Behat\Gherkin\Node\PyStringNode $list ) | ||
assertMustRevalidate ( $doesNotHave = false ) | ||
assertResponseBody ( $match, Behat\Gherkin\Node\PyStringNode $expected ) | ||
assertResponseBodyLength ( $length ) | ||
assertResponseHeader ( $header, $match, $value ) | ||
assertResponseIsCacheable ( $cacheable = true ) | ||
assertResponseStatus ( $status ) | ||
attachFileToRequestBody ( $path ) | ||
makeSameRequest ( $method ) | ||
performRequestWithGivenQueryString ( $path ) | ||
request ( $path, $method = 'GET' ) | ||
setOverrideMethodHeader ( string $method ) | Set method override header used to fake non-standard HTTP verbs | |
setRequestBody ( Behat\Gherkin\Node\PyStringNode $body ) | ||
setRequestHeader ( $header, $value ) | ||
setUp ( Behat\Behat\Event\SuiteEvent $event ) | Start up the built in httpd in php-5.4 | |
tearDown ( Behat\Behat\Event\SuiteEvent $event ) | Collect code coverage after the suite has been run |
메소드 | 설명 | |
---|---|---|
addHeaderToNextRequest ( string $key, mixed $value ) | Add a request header for the next request | |
getLastResponse ( ) : Guzzle\Http\Message\Response | Get the response to the last request made by the Guzzle client | |
getPreviousCacheControlHeader ( ) : Guzzle\Http\Message\Header\CacheControl | Get the cache-control header for the previous response |
메소드 | 설명 | |
---|---|---|
canConnectToHttpd ( string $host, integer $port ) : boolean | See if we have an httpd we can connect to | |
createClient ( ) | Create a new HTTP client | |
getOverrideVerbs ( ) | Returns a list of HTTP verbs that we need to do an override of in order to bypass limitations in the built-in PHP HTTP server. | |
startBuiltInHttpd ( string $host, integer $port, string $documentRoot, string $router, string $httpdLog ) : integer | Start the built in httpd in php-5.4 |
public __construct ( array $parameters ) | ||
$parameters | array | Context parameters |
protected addHeaderToNextRequest ( string $key, mixed $value ) | ||
$key | string | The name of the header |
$value | mixed | The value of the header |
public assertEqualResponseHeaders ( Behat\Gherkin\Node\PyStringNode $list ) | ||
$list | Behat\Gherkin\Node\PyStringNode |
public assertExistingHeaders ( Behat\Gherkin\Node\PyStringNode $list ) | ||
$list | Behat\Gherkin\Node\PyStringNode |
public assertHeaderNotSameForPreviousRequests ( $header ) |
public assertMissingHeaders ( Behat\Gherkin\Node\PyStringNode $list ) | ||
$list | Behat\Gherkin\Node\PyStringNode |
public assertResponseBody ( $match, Behat\Gherkin\Node\PyStringNode $expected ) | ||
$expected | Behat\Gherkin\Node\PyStringNode |
protected getLastResponse ( ) : Guzzle\Http\Message\Response | ||
리턴 | Guzzle\Http\Message\Response |
protected getPreviousCacheControlHeader ( ) : Guzzle\Http\Message\Header\CacheControl | ||
리턴 | Guzzle\Http\Message\Header\CacheControl | The Cache-Control header for the previous response |
public setOverrideMethodHeader ( string $method ) | ||
$method | string | Override method |
public setRequestBody ( Behat\Gherkin\Node\PyStringNode $body ) | ||
$body | Behat\Gherkin\Node\PyStringNode |
public static setUp ( Behat\Behat\Event\SuiteEvent $event ) | ||
$event | Behat\Behat\Event\SuiteEvent |
public static tearDown ( Behat\Behat\Event\SuiteEvent $event ) | ||
$event | Behat\Behat\Event\SuiteEvent |
protected Client,Guzzle\Http $client | ||
리턴 | Guzzle\Http\Client |
protected string $requestBody | ||
리턴 | string |