Skip to content

Commit

Permalink
Apply CS fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
mzur committed Aug 21, 2019
1 parent 84e0f99 commit 5d7f32a
Show file tree
Hide file tree
Showing 5 changed files with 55 additions and 53 deletions.
20 changes: 10 additions & 10 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
{
"name": "biigle/module",
"description": "A template for a new BIIGLE module.",
"name": "biigle/module",
"description": "A template for a new BIIGLE module.",
"keywords": ["biigle", "biigle-module"],
"license": "GPL-3.0-only",
"support": {
"source": "https://github.com/biigle/module",
"issues": "https://github.com/biigle/module/issues"
"source": "https://github.com/biigle/module",
"issues": "https://github.com/biigle/module/issues"
},
"homepage": "https://biigle.de",
"authors": [
{
"name": "Martin Zurowietz",
"email": "[email protected]"
}
{
"name": "Martin Zurowietz",
"email": "[email protected]"
}
],
"autoload": {
"autoload": {
"psr-4": {
"Biigle\\Modules\\Module\\": "src"
}
}
}
}
5 changes: 3 additions & 2 deletions src/Http/Controllers/QuotesController.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@

use Biigle\Http\Controllers\Views\Controller;

class QuotesController extends Controller {
class QuotesController extends Controller
{

/**
* Shows the quotes page.
Expand All @@ -23,6 +24,6 @@ public function index()
*/
public function quote()
{
return \Illuminate\Foundation\Inspiring::quote();
return \Illuminate\Foundation\Inspiring::quote();
}
}
35 changes: 18 additions & 17 deletions src/ModuleServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
use Illuminate\Routing\Router;
use Illuminate\Support\ServiceProvider;

class ModuleServiceProvider extends ServiceProvider {
class ModuleServiceProvider extends ServiceProvider
{

/**
* Bootstrap the application events.
Expand All @@ -15,18 +16,18 @@ class ModuleServiceProvider extends ServiceProvider {
* @param Router $router
* @return void
*/
public function boot(Modules $modules, Router $router)
{
$this->loadViewsFrom(__DIR__.'/resources/views', 'module');
public function boot(Modules $modules, Router $router)
{
$this->loadViewsFrom(__DIR__.'/resources/views', 'module');

$router->group([
$router->group([
'namespace' => 'Biigle\Modules\Module\Http\Controllers',
'middleware' => 'web',
], function ($router) {
require __DIR__.'/Http/routes.php';
});

$modules->register('module', [
$modules->register('module', [
'viewMixins' => [
'dashboardMain',
],
Expand All @@ -41,15 +42,15 @@ public function boot(Modules $modules, Router $router)
$this->publishes([
__DIR__.'/public/assets' => public_path('vendor/module'),
], 'public');
}

/**
* Register the service provider.
*
* @return void
*/
public function register()
{
//
}
}

/**
* Register the service provider.
*
* @return void
*/
public function register()
{
//
}
}
36 changes: 18 additions & 18 deletions tests/Http/Controllers/QuotesControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,27 @@
use TestCase;
use Biigle\Tests\UserTest;

class QuotesControllerTest extends TestCase {
class QuotesControllerTest extends TestCase
{
public function testRoute()
{
$user = UserTest::create();

public function testRoute()
{
$user = UserTest::create();
// Redirect to login page.
$this->get('quotes')->assertStatus(302);

// Redirect to login page.
$this->get('quotes')->assertStatus(302);
$this->be($user);
$this->get('quotes')->assertStatus(200);
}

$this->be($user);
$this->get('quotes')->assertStatus(200);
}
public function testQuoteProvider()
{
$user = UserTest::create();

public function testQuoteProvider()
{
$user = UserTest::create();
// Redirect to login page.
$this->get('quotes/new')->assertStatus(302);

// Redirect to login page.
$this->get('quotes/new')->assertStatus(302);

$this->be($user);
$this->get('quotes/new')->assertStatus(200);
}
$this->be($user);
$this->get('quotes/new')->assertStatus(200);
}
}
12 changes: 6 additions & 6 deletions tests/ModuleServiceProviderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
use TestCase;
use Biigle\Modules\Module\ModuleServiceProvider;

class ModuleServiceProviderTest extends TestCase {

public function testServiceProvider()
{
$this->assertTrue(class_exists(ModuleServiceProvider::class));
}
class ModuleServiceProviderTest extends TestCase
{
public function testServiceProvider()
{
$this->assertTrue(class_exists(ModuleServiceProvider::class));
}
}

0 comments on commit 5d7f32a

Please sign in to comment.