Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
<?php namespace Illuminate\Tests\Database; use Illuminate\Database\Connection; use Illum..
Decoded Output download
<?php
namespace Illuminate\Tests\Database;
use Illuminate\Database\Connection;
use Illuminate\Database\Schema\Grammars\Grammar;
use LogicException;
use Mockery as m;
use PHPUnit\Framework\TestCase;
class DatabaseAbstractSchemaGrammarTest extends TestCase
{
protected function tearDown(): void
{
m::close();
}
public function testCreateDatabase()
{
$grammar = new class extends Grammar {};
$this->expectException(LogicException::class);
$this->expectExceptionMessage('This database driver does not support creating databases.');
$grammar->compileCreateDatabase('foo', m::mock(Connection::class));
}
public function testDropDatabaseIfExists()
{
$grammar = new class extends Grammar {};
$this->expectException(LogicException::class);
$this->expectExceptionMessage('This database driver does not support dropping databases.');
$grammar->compileDropDatabaseIfExists('foo');
}
}
?>
Did this file decode correctly?
Original Code
<?php
namespace Illuminate\Tests\Database;
use Illuminate\Database\Connection;
use Illuminate\Database\Schema\Grammars\Grammar;
use LogicException;
use Mockery as m;
use PHPUnit\Framework\TestCase;
class DatabaseAbstractSchemaGrammarTest extends TestCase
{
protected function tearDown(): void
{
m::close();
}
public function testCreateDatabase()
{
$grammar = new class extends Grammar {};
$this->expectException(LogicException::class);
$this->expectExceptionMessage('This database driver does not support creating databases.');
$grammar->compileCreateDatabase('foo', m::mock(Connection::class));
}
public function testDropDatabaseIfExists()
{
$grammar = new class extends Grammar {};
$this->expectException(LogicException::class);
$this->expectExceptionMessage('This database driver does not support dropping databases.');
$grammar->compileDropDatabaseIfExists('foo');
}
}
Function Calls
None |
Stats
MD5 | 4e256584b045969ea8c6c9d206c9d8da |
Eval Count | 0 |
Decode Time | 102 ms |