adapt phpunit for windows (#36)

Co-authored-by: he426100 <{ID}+{username}@users.noreply.github.com>
This commit is contained in:
he426100
2024-01-15 11:28:33 +08:00
committed by GitHub
parent 3e80730042
commit 7a2b74aaee
3 changed files with 19 additions and 19 deletions
+3 -3
View File
@@ -7,9 +7,9 @@ class ModuleTest extends TestCase
{
public function testImport()
{
$os = PyLoader::import('os');
$uname = $os->uname();
$this->assertEquals($uname->sysname, 'Linux');
$platform = PyLoader::import('platform');
$uname = $platform->uname();
$this->assertStringContainsStringIgnoringCase([PHP_OS, 'WIN'][str_starts_with(PHP_OS, 'WIN')], (string)$uname->system);
}
public function testNewObject()