Skip to content

Commit

Permalink
Fix cs
Browse files Browse the repository at this point in the history
  • Loading branch information
odan committed Sep 10, 2023
1 parent 7640d46 commit d84829d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
1 change: 0 additions & 1 deletion config/routes.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
use Slim\Routing\RouteCollectorProxy;

return function (App $app) {
// Redirect to Swagger documentation
$app->get('/', \App\Action\Home\HomeAction::class)->setName('home');

// API
Expand Down
8 changes: 3 additions & 5 deletions tests/TestCase/Action/Customer/CustomerCreatorActionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,15 @@ public function testCreateCustomer(): void

$response = $this->app->handle($request);

// No logger errors
$this->assertSame([], $this->getLoggerErrors());
$this->assertTrue($this->getLogger()->hasInfoThatContains('Customer created successfully: 1'));

// Check response
$this->assertSame(StatusCodeInterface::STATUS_CREATED, $response->getStatusCode());
$this->assertJsonContentType($response);
$this->assertJsonData(['customer_id' => 1], $response);

// Check logger
$this->assertTrue($this->getLogger()->hasInfoThatContains('Customer created successfully'));
// No logger errors
$this->assertSame([], $this->getLoggerErrors());
$this->assertTrue($this->getLogger()->hasInfoThatContains('Customer created successfully: 1'));

// Check database
$this->assertTableRowCount(1, 'customers');
Expand Down

0 comments on commit d84829d

Please sign in to comment.