~tcuthbert/wordpress/openstack-objectstorage

« back to all changes in this revision

Viewing changes to vendor/guzzlehttp/guzzle/tests/Event/RequestAfterSendEventTest.php

  • Committer: Jacek Nykis
  • Date: 2015-02-11 15:35:31 UTC
  • Revision ID: jacek.nykis@canonical.com-20150211153531-hmy6zi0ov2qfkl0b
Initial commit

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?php
 
2
 
 
3
namespace GuzzleHttp\Tests\Event;
 
4
 
 
5
use GuzzleHttp\Adapter\Transaction;
 
6
use GuzzleHttp\Client;
 
7
use GuzzleHttp\Event\CompleteEvent;
 
8
use GuzzleHttp\Message\Request;
 
9
use GuzzleHttp\Message\Response;
 
10
 
 
11
/**
 
12
 * @covers GuzzleHttp\Event\CompleteEvent
 
13
 */
 
14
class CompleteEventTest extends \PHPUnit_Framework_TestCase
 
15
{
 
16
    public function testHasValues()
 
17
    {
 
18
        $c = new Client();
 
19
        $r = new Request('GET', '/');
 
20
        $res = new Response(200);
 
21
        $t = new Transaction($c, $r);
 
22
        $e = new CompleteEvent($t);
 
23
        $e->intercept($res);
 
24
        $this->assertTrue($e->isPropagationStopped());
 
25
        $this->assertSame($res, $e->getResponse());
 
26
    }
 
27
}