Migriert die weiterhin benötigten Zeitaufgaben einschließlich SOAP-Importen, Betriebsstatus und Wiederanlaufkontrolle. Aktiviert 115 native Spring-Tasks im Docker-Image ohne Cron-Daemon oder PHP und dokumentiert die entfallenen HHA-Aufrufe. Ergänzt PHP-/UI-Testwerkzeuge und aktualisiert den Projektstand auf Version 0.2.0.
23 lines
838 B
PHP
23 lines
838 B
PHP
<?php
|
|
|
|
use PHPUnit\Framework\Attributes\DataProvider;
|
|
|
|
final class ConditionTest extends LegacyTestCase
|
|
{
|
|
#[DataProvider('conditions')]
|
|
public function testComparisonOperators(mixed $value, string $operator, mixed $compare, bool $expected): void
|
|
{
|
|
self::assertSame($expected, mcCheckCondition($value, $operator, $compare));
|
|
}
|
|
|
|
public static function conditions(): array
|
|
{
|
|
return [[5, '==', '5', true], [5, '==', 6, false], [5, '!=', 6, true],
|
|
[5, '!=', '5', false], [4, '<', 5, true], [5, '<', 5, false],
|
|
[6, '>', 5, true], [5, '>', 5, false], [5, '<=', 5, true],
|
|
[6, '<=', 5, false], [5, '>=', 5, true], [4, '>=', 5, false],
|
|
['10', '<', '2', false], ['text', '==', 'text', true],
|
|
[1, '===', 1, false], [1, 'invalid', 1, false]];
|
|
}
|
|
}
|