Skip to content

Commit

Permalink
Added note about enableRetainFlashMessages in constraint error
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyharris committed May 25, 2018
1 parent 88417f8 commit 58d5628
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/TestSuite/Constraint/Session/FlashParamEquals.php
Expand Up @@ -57,7 +57,9 @@ public function __construct($session, $key, $param, $at = null)
parent::__construct();

if (!$session) {
throw new AssertionFailedError('There is no stored session data. Perhaps you need to run a request?');
$message = 'There is no stored session data. Perhaps you need to run a request?';
$message .= ' Additionally, ensure `$this->enableRetainFlashMessages()` has been enabled for the test.';
throw new AssertionFailedError($message);
}

$this->session = $session;
Expand Down

0 comments on commit 58d5628

Please sign in to comment.