You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
1.2 KiB
44 lines
1.2 KiB
<?php
|
|
|
|
namespace Tests;
|
|
|
|
class ConfigTest extends TestCase
|
|
{
|
|
/** @test */
|
|
public function it_has_config_file()
|
|
{
|
|
$this->assertTrue(is_array(config('simple-crud')));
|
|
}
|
|
|
|
/** @test */
|
|
public function it_has_default_layout_view_config()
|
|
{
|
|
$this->assertEquals('layouts.app', config('simple-crud.default_layout_view'));
|
|
|
|
config(['simple-crud.default_layout_view' => 'layouts.master']);
|
|
|
|
$this->assertEquals('layouts.master', config('simple-crud.default_layout_view'));
|
|
}
|
|
|
|
/** @test */
|
|
public function it_has_base_test_path_config()
|
|
{
|
|
$this->assertEquals('tests/BrowserKitTest.php', config('simple-crud.base_test_path'));
|
|
}
|
|
|
|
/** @test */
|
|
public function it_has_base_test_class_config()
|
|
{
|
|
$this->assertEquals('Tests\BrowserKitTest', config('simple-crud.base_test_class'));
|
|
}
|
|
|
|
/** @test */
|
|
public function config_file_can_be_published()
|
|
{
|
|
$this->artisan('vendor:publish', ['--tag' => 'config', '--no-interaction' => true]);
|
|
|
|
$this->assertFileExists(config_path('simple-crud.php'));
|
|
|
|
$this->removeFileOrDir(config_path('simple-crud.php'));
|
|
}
|
|
}
|