B
B
BonBon Slick2018-05-23 19:48:15
symfony
BonBon Slick, 2018-05-23 19:48:15

PhPUnit ErrorException: unserialize(): Error at offset 0 of 68 bytes?

PhPUnit 7.1

public function AuthenticationForm_WithValidCredentials_Submit() : void
    {
        $client = static::createClient([], ['HTTPS' => true]);
        $crawler = $client->request('GET', '/en/login');
        $form = $crawler->filter('form')->form();
        $form->setValues(['email' => '[email protected]', 'password' => 'admin']);
        $crawler = $client->submit($form);
        dump($crawler);

ERROR
1) App\Infrastructure\Tests\Functional\AuthFunctionalTest::AuthenticationForm_WithValidCredentials_Submit
PHPUnit\Framework\Exception: Doctrine\Common\Collections\ArrayCollection {#480
  -elements: []
}

Caused by
ErrorException: unserialize(): Error at offset 0 of 68 bytes in /var/www/test/vendor/phpunit/phpunit/src/Util/PHP/AbstractPhpProcess.php:247
Stack trace:
#0 [internal function]: PHPUnit\Util\PHP\AbstractPhpProcess->PHPUnit\Util\PHP\{closure}(8, 'unserialize(): ...', '/var/www/test...', 247, Array)
#1 /var/www/test/vendor/phpunit/phpunit/src/Util/PHP/AbstractPhpProcess.php(247): unserialize('Doctrine\\Common...')
#2 /var/www/test/vendor/phpunit/phpunit/src/Util/PHP/AbstractPhpProcess.php(171): PHPUnit\Util\PHP\AbstractPhpProcess->processChildResult(Object(App\Infrastructure\Tests\Functional\AuthFunctionalTest), Object(PHPUnit\Framework\TestResult), 'Doctrine\\Common...', '')

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question