Skip to content

Commit

Permalink
remove hardcoded values
Browse files Browse the repository at this point in the history
  • Loading branch information
pxpm authored and freekmurze committed Jan 27, 2025
1 parent f5a238f commit 074e35f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions tests/Config/ConfigTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,14 @@
$config = Config::fromArray(config('backup'));

expect($config->backup->destination)->toBeInstanceOf(DestinationConfig::class);
expect($config->backup->destination->compressionMethod)->toBe(-1);
});
expect($config->backup->destination->compressionMethod)->toBe(ZipArchive::CM_DEFAULT);
})->only();

it('merges the published config file with package config file and preserve published config values', function () {
config()->set('backup.backup.destination', ['compression_method' => 2]);
config()->set('backup.backup.destination', ['compression_method' => ZipArchive::CM_DEFLATE]);

$config = Config::fromArray(config('backup'));

expect($config->backup->destination)->toBeInstanceOf(DestinationConfig::class);
expect($config->backup->destination->compressionMethod)->toBe(2);
});
expect($config->backup->destination->compressionMethod)->toBe(ZipArchive::CM_DEFLATE);
})->only();

0 comments on commit 074e35f

Please sign in to comment.