This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Belevo\EnelixEMS\Tests;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
final class BatterieTimerLifecycleTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* @runInSeparateProcess
|
||||
* @preserveGlobalState disabled
|
||||
*/
|
||||
public function testTimerWrapperUndStriktPassiverRueckmeldecache(): void
|
||||
{
|
||||
global $count;
|
||||
ob_start();
|
||||
try {
|
||||
require __DIR__ . '/BatterieTimer/lifecycle_checks.php';
|
||||
$output = (string) ob_get_contents();
|
||||
} finally {
|
||||
ob_end_clean();
|
||||
}
|
||||
self::assertSame(28, $count);
|
||||
self::assertSame(0, $GLOBALS['deviceCalls']);
|
||||
self::assertStringContainsString('TOTAL 28 offline battery timer/cache contract checks passed.', $output);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user