Skip to content

Commit

Permalink
#75 #in_progress #comment add Test Class CommandManage
Browse files Browse the repository at this point in the history
  • Loading branch information
bfoujols committed Sep 6, 2022
1 parent 0502a5e commit bc04bf0
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 12 deletions.
24 changes: 12 additions & 12 deletions clover.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<coverage generated="1662411121">
<project timestamp="1662411121">
<coverage generated="1662497005">
<project timestamp="1662497005">
<file name="/Users/redbull/Projects/poc/cli-manage-student/src/App.php">
<class name="Studoo\App" namespace="global">
<metrics complexity="1" methods="1" coveredmethods="0" conditionals="0" coveredconditionals="0"
Expand All @@ -21,17 +21,17 @@
<metrics complexity="5" methods="2" coveredmethods="1" conditionals="0" coveredconditionals="0"
statements="7" coveredstatements="5" elements="9" coveredelements="6"/>
</class>
<line num="14" type="method" name="initialize" visibility="protected" complexity="4" crap="4.59"
<line num="23" type="method" name="initialize" visibility="protected" complexity="4" crap="4.59"
count="11"/>
<line num="16" type="stmt" count="11"/>
<line num="19" type="stmt" count="11"/>
<line num="20" type="stmt" count="0"/>
<line num="21" type="stmt" count="11"/>
<line num="22" type="stmt" count="0"/>
<line num="25" type="stmt" count="11"/>
<line num="28" type="method" name="getStdOutPut" visibility="public" complexity="1" crap="1" count="9"/>
<line num="30" type="stmt" count="9"/>
<metrics loc="33" ncloc="32" classes="1" methods="2" coveredmethods="1" conditionals="0"
<line num="28" type="stmt" count="11"/>
<line num="29" type="stmt" count="0"/>
<line num="30" type="stmt" count="11"/>
<line num="31" type="stmt" count="0"/>
<line num="34" type="stmt" count="11"/>
<line num="37" type="method" name="getStdOutPut" visibility="public" complexity="1" crap="1" count="9"/>
<line num="39" type="stmt" count="9"/>
<metrics loc="42" ncloc="33" classes="1" methods="2" coveredmethods="1" conditionals="0"
coveredconditionals="0" statements="7" coveredstatements="5" elements="9" coveredelements="6"/>
</file>
<file name="/Users/redbull/Projects/poc/cli-manage-student/src/Command/CreateFileDefaultCommand.php">
Expand Down Expand Up @@ -759,7 +759,7 @@
<metrics loc="50" ncloc="39" classes="1" methods="2" coveredmethods="0" conditionals="0"
coveredconditionals="0" statements="8" coveredstatements="0" elements="10" coveredelements="0"/>
</file>
<metrics files="36" loc="1916" ncloc="1395" classes="28" methods="99" coveredmethods="70" conditionals="0"
<metrics files="36" loc="1925" ncloc="1396" classes="28" methods="99" coveredmethods="70" conditionals="0"
coveredconditionals="0" statements="367" coveredstatements="283" elements="466" coveredelements="353"/>
</project>
</coverage>
9 changes: 9 additions & 0 deletions src/Command/CommandManage.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
<?php
/*
* Ce fichier fait partie du Studoo.
*
* (c) Benoit Foujols <Benoit.Foujols@ac-creteil.fr>
*
* Pour les informations complètes sur les droits d'auteur et la licence,
* veuillez consulter le fichier LICENSE qui a été distribué avec ce code source.
*/

namespace Studoo\Command;

Expand All @@ -7,6 +15,7 @@
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Console\Style\SymfonyStyle;


class CommandManage extends Command
{
protected static SymfonyStyle $stdOutput;
Expand Down
25 changes: 25 additions & 0 deletions tests/Command/CommandManageTest.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?php

namespace Command;

use Studoo\Command\CommandManage;
use PHPUnit\Framework\TestCase;

class CommandManageTest extends TestCase
{
private $CommandManage;

protected function setUp(): void
{
$this->CommandManage = new CommandManage();
}

/**
* @test CommandManage01
*/
public function testCommandeManage(): void
{
$this->assertIsObject($this->CommandManage);
}

}

0 comments on commit bc04bf0

Please sign in to comment.