I am getting this warning when i run phpunit on command line :
PHPUnit 5.1.3 by Sebastian Bergmann and contributors.
Time: 114 ms, Memory: 4.00MB
No tests executed!
here is my framework folders structure :
.
├── App
├── CHANGELOG
├── composer.json
├── composer.lock
├── Config
├── Database
├── local.env.php
├── phpunit.xml
├── public
├── README.md
├── robot.txt
├── silver
├── Storage
├── System
├── Tests
└── vendor
Test directory :
Tests
└── Unit
└── ControllerTest.php
phpunit.xml:
<?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="false"
backupStaticAttributes="false"
bootstrap="vendor/autoload.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false">
<testsuites>
<testsuite name="Unit">
<directory suffix="Test.php">./Tests/Unit</directory>
</testsuite>
</testsuites>
</phpunit>
composer.json file :
"autoload-dev": {
"psr-4": {
"Tests\\": "Tests/"
}
}
controllerTest class :
<?php
namespace Tests\Unit;
use \PHPUnit\Framework\TestCase;
class ControllerTest extends TestCase
{
/** @test */
public function testFirstMethod()
{
$num = 20;
$this->assertEquals(22, $num);
}
}
Any suggestions or help would be very appreciated thanks.