src/Concerns/MakesAssertions.php
public function assertDialogOpened($message)
    {
        $actualMessage = $this->driver->switchTo()->alert()->getText();

        PHPUnit::assertEquals(
            $message, $actualMessage,
            "Expected dialog message [{$message}] does not equal actual message [{$actualMessage}]."
        );

        return $this;
    }
public function assertDialogOpened($message)
    {
        $actualMessage = $this->driver->switchTo()->alert()->getText();

        PHPUnit::assertEquals(
            $message, $actualMessage,
            "Expected dialog message [{$message}] does not equal actual message [{$actualMessage}]."
        );

        return $this;
    }
public function assertDialogOpened ( $ message ) { $ actualMessage = $ this -> driver -> switchTo ( ) -> alert ( ) -> getText ( ) ; PHPUnit :: assertEquals ( $ message , $ actualMessage , "Expected dialog message [{$message}] does not equal actual message [{$actualMessage}]." ) ; return $ this ; }
Assert that a JavaScript dialog with given message has been opened.

@param  string  $message
@return $this
Assert that a JavaScript dialog with given message has been opened .