Skip to content

Commit

Permalink
rename OutputBuffering to OutputBufferingMiddleware
Browse files Browse the repository at this point in the history
  • Loading branch information
campersau committed Aug 15, 2017
1 parent ee32eb6 commit 5c418b0
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

### Added

- [#2166](https://github.com/slimphp/Slim/pull/2166) Added Middleware\OutputBuffering
- [#2166](https://github.com/slimphp/Slim/pull/2166) Added Middleware\OutputBufferingMiddleware

### Deprecated

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
use Psr\Http\Message\ResponseInterface;
use Slim\Http\Body;

class OutputBuffering
class OutputBufferingMiddleware
{
const APPEND = 'append';
const PREPEND = 'prepend';
Expand Down
2 changes: 1 addition & 1 deletion UPGRADING.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# How to upgrade

* [2166] - You need to add the `Middleware\OutputBuffering` middleware to capture echo'd or var_dump'd output from your code.
* [2166] - You need to add the `Middleware\OutputBufferingMiddleware` middleware to capture echo'd or var_dump'd output from your code.
* [2098] - You need to add the App's router to the container for a straight upgrade. If you've created your own router factory in the container though, then you need to set it into the $app.
* [2102] - You must inject custom route invocation strategy with `$app->getRouter()->setDefaultInvocationStrategy($myStrategy)`

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,20 @@
use Slim\Http\Request;
use Slim\Http\Response;
use Slim\Http\Uri;
use Slim\Middleware\OutputBuffering;
use Slim\Middleware\OutputBufferingMiddleware;

class OutputBufferingTest extends TestCase
class OutputBufferingMiddlewareTest extends TestCase
{
public function testStyleDefaultValid()
{
$mw = new OutputBuffering();
$mw = new OutputBufferingMiddleware();

$this->assertAttributeEquals('append', 'style', $mw);
}

public function testStyleCustomValid()
{
$mw = new OutputBuffering('prepend');
$mw = new OutputBufferingMiddleware('prepend');

$this->assertAttributeEquals('prepend', 'style', $mw);
}
Expand All @@ -39,12 +39,12 @@ public function testStyleCustomValid()
*/
public function testStyleCustomInvalid()
{
$mw = new OutputBuffering('foo');
$mw = new OutputBufferingMiddleware('foo');
}

public function testAppend()
{
$mw = new OutputBuffering('append');
$mw = new OutputBufferingMiddleware('append');

$uri = Uri::createFromString('https://example.com:443/foo/bar?abc=123');
$headers = new Headers();
Expand All @@ -67,7 +67,7 @@ public function testAppend()

public function testPrepend()
{
$mw = new OutputBuffering('prepend');
$mw = new OutputBufferingMiddleware('prepend');

$uri = Uri::createFromString('https://example.com:443/foo/bar?abc=123');
$headers = new Headers();
Expand Down

0 comments on commit 5c418b0

Please sign in to comment.