Skip to content

Commit

Permalink
Make fragile test less fragile.
Browse files Browse the repository at this point in the history
  • Loading branch information
markstory committed Nov 2, 2012
1 parent ddd3baf commit 118dd8c
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions lib/Cake/Test/Case/View/MediaViewTest.php
Expand Up @@ -132,11 +132,14 @@ public function testRenderWithUnknownFileTypeGeneric() {

$this->MediaView->response->expects($this->at(1))
->method('header')
->with(array(
'Date' => gmdate('D, d M Y H:i:s', time()) . ' GMT',
'Expires' => '0',
'Cache-Control' => 'private, must-revalidate, post-check=0, pre-check=0',
'Pragma' => 'no-cache'
->with($this->logicalAnd(
$this->arrayHasKey('Date'),
$this->arrayHasKey('Expires'),
$this->arrayHasKey('Cache-Control'),
$this->arrayHasKey('Pragma'),
$this->contains('0'),
$this->contains('private, must-revalidate, post-check=0, pre-check=0'),
$this->contains('no-cache')
));

$this->MediaView->response->expects($this->once())
Expand Down

0 comments on commit 118dd8c

Please sign in to comment.