Skip to content

Commit

Permalink
upd test
Browse files Browse the repository at this point in the history
  • Loading branch information
aVadim483 committed Jan 2, 2025
1 parent e050739 commit 00c01bc
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions tests/FastExcelWriterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,13 @@ protected function saveCheckRead($excel, $testFileName): ExcelReader
var_dump($text);
}
$this->assertTrue($valid);
$vbsChecker = __DIR__ . '/check_open_xlsx.vbs';
if (is_file($vbsChecker)) {
system("$vbsChecker $testFileName", $result);
$this->assertEquals(0, $result);

if (substr(PHP_OS, 0, 3) === 'WIN') {
$vbsChecker = __DIR__ . '/check_open_xlsx.vbs';
if (is_file($vbsChecker)) {
system("$vbsChecker $testFileName", $result);
$this->assertEquals(0, $result);
}
}

return ExcelReader::open($testFileName);
Expand Down

0 comments on commit 00c01bc

Please sign in to comment.