mirror of
https://github.com/Karaka-Management/oms-Navigation.git
synced 2026-01-23 22:08:40 +00:00
fix tests and replace file_exists
This commit is contained in:
parent
c270825cea
commit
e7ba5bf7b6
|
|
@ -120,7 +120,7 @@ final class BackendController extends Controller
|
|||
foreach ($languages as $path) {
|
||||
$path = __DIR__ . '/../../..' . $path . '.' . $langCode . '.lang.php';
|
||||
|
||||
if (!\file_exists($path)) {
|
||||
if (!\is_file($path)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -106,7 +106,7 @@ final class SearchController extends Controller
|
|||
foreach ($languages as $path) {
|
||||
$path = __DIR__ . '/../../..' . $path . '.' . $langCode . '.lang.php';
|
||||
|
||||
if (!\file_exists($path)) {
|
||||
if (!\is_file($path)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ final class TimerecordingController extends Controller
|
|||
foreach ($languages as $path) {
|
||||
$path = __DIR__ . '/../../..' . $path . '.' . $langCode . '.lang.php';
|
||||
|
||||
if (!\file_exists($path)) {
|
||||
if (!\is_file($path)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -21,6 +21,10 @@ use Modules\Navigation\Views\NavigationView;
|
|||
*/
|
||||
class NavigationViewTest extends \PHPUnit\Framework\TestCase
|
||||
{
|
||||
/**
|
||||
* @covers Modules\Navigation\Views\NavigationView
|
||||
* @group module
|
||||
*/
|
||||
public function testDefault() : void
|
||||
{
|
||||
$view = new NavigationView();
|
||||
|
|
@ -30,6 +34,10 @@ class NavigationViewTest extends \PHPUnit\Framework\TestCase
|
|||
self::assertEquals(0, $view->getParent());
|
||||
}
|
||||
|
||||
/**
|
||||
* @covers Modules\Navigation\Views\NavigationView
|
||||
* @group module
|
||||
*/
|
||||
public function testGetSet() : void
|
||||
{
|
||||
$view = new NavigationView();
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user