Skip to content

Commit

Permalink
Clean logs files only once at bootstrap; to prevent issues when mcn > 1
Browse files Browse the repository at this point in the history
  • Loading branch information
trasher committed Aug 6, 2018
1 parent d9f4783 commit da16f8d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
7 changes: 0 additions & 7 deletions tests/GLPITestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,6 @@ public function afterTestMethod($method) {
}
$GLPI_CACHE = false;
}

// Cleanup log directory
foreach (glob(GLPI_LOG_DIR . '/*.log') as $file) {
if (file_exists($file)) {
unlink($file);
}
}
}

/**
Expand Down
7 changes: 7 additions & 0 deletions tests/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -582,4 +582,11 @@ function getItemByTypeName($type, $name, $onlyid = false) {
return false;
}

// Cleanup log directory
foreach (glob(GLPI_LOG_DIR . '/*.log') as $file) {
if (file_exists($file)) {
unlink($file);
}
}

loadDataset();

0 comments on commit da16f8d

Please sign in to comment.