finishes 13 and 14
This commit is contained in:
53
tests/Unit/ScoringServiceTest.php
Normal file
53
tests/Unit/ScoringServiceTest.php
Normal file
@@ -0,0 +1,53 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Tests\Unit;
|
||||
|
||||
use App\Services\ScoringService;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class ScoringServiceTest extends TestCase
|
||||
{
|
||||
public function test_determine_result_returns_go_for_score_ten(): void
|
||||
{
|
||||
$service = new ScoringService;
|
||||
|
||||
$this->assertEquals('go', $service->determineResult(10));
|
||||
}
|
||||
|
||||
public function test_determine_result_returns_go_for_score_above_ten(): void
|
||||
{
|
||||
$service = new ScoringService;
|
||||
|
||||
$this->assertEquals('go', $service->determineResult(15));
|
||||
}
|
||||
|
||||
public function test_determine_result_returns_consult_leadership_for_score_nine(): void
|
||||
{
|
||||
$service = new ScoringService;
|
||||
|
||||
$this->assertEquals('consult_leadership', $service->determineResult(9));
|
||||
}
|
||||
|
||||
public function test_determine_result_returns_consult_leadership_for_score_five(): void
|
||||
{
|
||||
$service = new ScoringService;
|
||||
|
||||
$this->assertEquals('consult_leadership', $service->determineResult(5));
|
||||
}
|
||||
|
||||
public function test_determine_result_returns_no_go_for_score_four(): void
|
||||
{
|
||||
$service = new ScoringService;
|
||||
|
||||
$this->assertEquals('no_go', $service->determineResult(4));
|
||||
}
|
||||
|
||||
public function test_determine_result_returns_no_go_for_score_zero(): void
|
||||
{
|
||||
$service = new ScoringService;
|
||||
|
||||
$this->assertEquals('no_go', $service->determineResult(0));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user