Files
faveo/vendor/davejamesmiller/laravel-breadcrumbs/tests/integration/DependantServiceProviderErrorTest.php
2016-06-13 20:41:55 +05:30

44 lines
816 B
PHP

<?php
class DependantServiceProviderErrorTest extends TestCase {
protected function getPackageProviders()
{
return [
// These are in the wrong order
'DependantServiceProviderError',
'DaveJamesMiller\Breadcrumbs\ServiceProvider',
];
}
protected function loadServiceProvider()
{
// Disabled - we want to test the automatic loading instead
}
/**
* @expectedException DaveJamesMiller\Breadcrumbs\Exception
* @expectedExceptionMessage Breadcrumbs view not specified
*/
public function testRender()
{
Breadcrumbs::render('home');
}
}
class DependantServiceProviderError extends Illuminate\Support\ServiceProvider {
public function register()
{
}
public function boot()
{
Breadcrumbs::register('home', function($breadcrumbs) {
$breadcrumbs->push('Home', '/');
});
}
}