Skip to content

Commit 9693721

Browse files
JonasHaouzidbu
authored andcommitted
Asserting hits followed with a numerical number (#298)
Allow HIT or MISS header to have additional information and still be detected in test
1 parent 18f85f6 commit 9693721

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Test/PHPUnit/AbstractCacheConstraint.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ protected function matches($other)
6464
throw new \RuntimeException($message);
6565
}
6666

67-
return $this->getValue() === (string) $other->getHeaderLine($this->header);
67+
return strpos((string) $other->getHeaderLine($this->header), $this->getValue()) !== false;
6868
}
6969

7070
/**

0 commit comments

Comments
 (0)