Changeset View
Changeset View
Standalone View
Standalone View
src/tests/TestCase.php
<?php | <?php | ||||
namespace Tests; | namespace Tests; | ||||
use App\Domain; | use App\Domain; | ||||
use App\User; | use App\User; | ||||
use Illuminate\Foundation\Testing\TestCase as BaseTestCase; | use Illuminate\Foundation\Testing\TestCase as BaseTestCase; | ||||
use Illuminate\Support\Facades\Queue; | use Illuminate\Support\Facades\Queue; | ||||
abstract class TestCase extends BaseTestCase | abstract class TestCase extends BaseTestCase | ||||
{ | { | ||||
use CreatesApplication; | use CreatesApplication; | ||||
protected function assertEqual($a, $b) | |||||
{ | |||||
$this->assertTrue($a instanceof int); | |||||
$this->assertTrue($b instanceof int); | |||||
$this->assertTrue($a == $b); | |||||
return true; | |||||
} | |||||
protected function deleteTestDomain($name) | protected function deleteTestDomain($name) | ||||
{ | { | ||||
Queue::fake(); | Queue::fake(); | ||||
$domain = Domain::withTrashed()->where('namespace', $name)->first(); | $domain = Domain::withTrashed()->where('namespace', $name)->first(); | ||||
if (!$domain) { | if (!$domain) { | ||||
return; | return; | ||||
} | } | ||||
▲ Show 20 Lines • Show All 55 Lines • Show Last 20 Lines |