Compare commits
1
Commits
745726dad7
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
297f4a276a |
@@ -14,7 +14,16 @@ $root = dirname(__DIR__, 2);
|
|||||||
|
|
||||||
// --- Synchronisation dons.php / dons.php.sample -----------------------------
|
// --- Synchronisation dons.php / dons.php.sample -----------------------------
|
||||||
|
|
||||||
$donsLive = file_get_contents($root . '/dons.php');
|
// dons.php est une copie d'instance ignorée par git : dans le CI elle est
|
||||||
|
// absente, on la crée depuis le .sample pour les tests et on la nettoie après.
|
||||||
|
$donsLivePath = $root . '/dons.php';
|
||||||
|
$donsLiveCreated = false;
|
||||||
|
if (!file_exists($donsLivePath)) {
|
||||||
|
copy($root . '/dons.php.sample', $donsLivePath);
|
||||||
|
$donsLiveCreated = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
$donsLive = file_get_contents($donsLivePath);
|
||||||
$donsSample = file_get_contents($root . '/dons.php.sample');
|
$donsSample = file_get_contents($root . '/dons.php.sample');
|
||||||
|
|
||||||
assertContains(
|
assertContains(
|
||||||
@@ -206,3 +215,7 @@ foreach ($phpErrorNeedles as $needle) {
|
|||||||
foreach ($createdCopies as $copyPath) {
|
foreach ($createdCopies as $copyPath) {
|
||||||
unlink($copyPath);
|
unlink($copyPath);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($donsLiveCreated) {
|
||||||
|
unlink($donsLivePath);
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user