-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #69 from TomHAnderson/feature/workbench
Feature/workbench
- Loading branch information
Showing
23 changed files
with
302 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
providers: | ||
- LaravelDoctrine\ORM\DoctrineServiceProvider | ||
- LaravelDoctrine\Extensions\BeberleiExtensionsServiceProvider | ||
- LaravelDoctrine\Extensions\GedmoExtensionsServiceProvider | ||
|
||
workbench: | ||
start: '/' | ||
install: true | ||
health: false | ||
discovers: | ||
web: false | ||
api: false | ||
commands: false | ||
components: false | ||
views: false | ||
assets: | ||
- laravel-assets | ||
sync: [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
tests/Feature/GedmoExtensionsServiceProviderAllMappingsTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace LaravelDoctrineTest\Extensions\Feature; | ||
|
||
use Illuminate\Config\Repository; | ||
|
||
use function tap; | ||
|
||
class GedmoExtensionsServiceProviderAllMappingsTest extends TestCase | ||
{ | ||
protected function defineEnvironment(mixed $app): void | ||
{ | ||
// Setup default database to use sqlite :memory: | ||
tap($app['config'], static function (Repository $config): void { | ||
$config->set('doctrine.gedmo.all_mappings', true); | ||
}); | ||
} | ||
|
||
public function testCustomExtensionsCanBeRegistered(): void | ||
{ | ||
$this->app['events']->dispatch('doctrine.extensions.booting'); | ||
|
||
$this->assertTrue(true); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace LaravelDoctrineTest\Extensions\Feature; | ||
|
||
class GedmoExtensionsServiceProviderTest extends TestCase | ||
{ | ||
public function testCustomExtensionsCanBeRegistered(): void | ||
{ | ||
$this->app['events']->dispatch('doctrine.extensions.booting'); | ||
|
||
$this->assertTrue(true); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
<?php | ||
|
||
namespace Workbench\App\Models; | ||
|
||
// use Illuminate\Contracts\Auth\MustVerifyEmail; | ||
use Illuminate\Database\Eloquent\Factories\HasFactory; | ||
use Illuminate\Foundation\Auth\User as Authenticatable; | ||
use Illuminate\Notifications\Notifiable; | ||
use Laravel\Sanctum\HasApiTokens; | ||
|
||
class User extends Authenticatable | ||
{ | ||
use HasFactory, Notifiable; | ||
|
||
/** | ||
* The attributes that are mass assignable. | ||
* | ||
* @var array<int, string> | ||
*/ | ||
protected $fillable = [ | ||
'name', | ||
'email', | ||
'password', | ||
]; | ||
|
||
/** | ||
* The attributes that should be hidden for serialization. | ||
* | ||
* @var array<int, string> | ||
*/ | ||
protected $hidden = [ | ||
'password', | ||
'remember_token', | ||
]; | ||
|
||
/** | ||
* The attributes that should be cast. | ||
* | ||
* @var array<string, string> | ||
*/ | ||
protected $casts = [ | ||
'email_verified_at' => 'datetime', | ||
'password' => 'hashed', | ||
]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?php | ||
|
||
namespace Workbench\App\Providers; | ||
|
||
use Illuminate\Support\ServiceProvider; | ||
|
||
class WorkbenchServiceProvider extends ServiceProvider | ||
{ | ||
/** | ||
* Register services. | ||
*/ | ||
public function register(): void | ||
{ | ||
// | ||
} | ||
|
||
/** | ||
* Bootstrap services. | ||
*/ | ||
public function boot(): void | ||
{ | ||
// | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?php | ||
|
||
use Illuminate\Foundation\Application; | ||
use Illuminate\Foundation\Configuration\Exceptions; | ||
use Illuminate\Foundation\Configuration\Middleware; | ||
|
||
use function Orchestra\Testbench\default_skeleton_path; | ||
|
||
return Application::configure(basePath: $APP_BASE_PATH ?? default_skeleton_path()) | ||
->withRouting( | ||
web: __DIR__.'/../routes/web.php', | ||
commands: __DIR__.'/../routes/console.php', | ||
) | ||
->withMiddleware(function (Middleware $middleware) { | ||
// | ||
}) | ||
->withExceptions(function (Exceptions $exceptions) { | ||
// | ||
})->create(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<?php | ||
|
||
return [ | ||
// | ||
]; |
Empty file.
Oops, something went wrong.