Merge pull request #177 from dantleech/throw-exception-mink-not-set

Throw exception if mink has not been set in context
This commit is contained in:
Christophe Coevoet
2015-01-19 00:21:28 +01:00

View File

@@ -42,6 +42,13 @@ class RawMinkContext implements MinkAwareContext
*/ */
public function getMink() public function getMink()
{ {
if (null === $this->mink) {
throw new \RuntimeException(
'Mink instance has not been set on Mink context class. ' .
'Have you enabled the Mink Extension?'
);
}
return $this->mink; return $this->mink;
} }