diff options
author | ArthurHoaro <arthur@hoa.ro> | 2020-10-13 13:30:37 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-13 13:30:37 +0200 |
commit | 29c31b7ec6ca48ba37b7eb6da650931fd0cb7164 (patch) | |
tree | e4017d3c979604f40e78cdc305f0ab191aedd4b9 /tests/feed | |
parent | 458b6b9918ec27154dd45416947bb93bedb97109 (diff) | |
parent | fd1ddad98df45bc3c18be7980c1cbe68ce6b219c (diff) | |
download | Shaarli-29c31b7ec6ca48ba37b7eb6da650931fd0cb7164.tar.gz Shaarli-29c31b7ec6ca48ba37b7eb6da650931fd0cb7164.tar.zst Shaarli-29c31b7ec6ca48ba37b7eb6da650931fd0cb7164.zip |
Merge pull request #1570 from ArthurHoaro/feature/datastore-mutex
Add mutex on datastore I/O operations
Diffstat (limited to 'tests/feed')
-rw-r--r-- | tests/feed/FeedBuilderTest.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/feed/FeedBuilderTest.php b/tests/feed/FeedBuilderTest.php index c29e8ef3..6b9204eb 100644 --- a/tests/feed/FeedBuilderTest.php +++ b/tests/feed/FeedBuilderTest.php | |||
@@ -3,6 +3,7 @@ | |||
3 | namespace Shaarli\Feed; | 3 | namespace Shaarli\Feed; |
4 | 4 | ||
5 | use DateTime; | 5 | use DateTime; |
6 | use malkusch\lock\mutex\NoMutex; | ||
6 | use ReferenceLinkDB; | 7 | use ReferenceLinkDB; |
7 | use Shaarli\Bookmark\Bookmark; | 8 | use Shaarli\Bookmark\Bookmark; |
8 | use Shaarli\Bookmark\BookmarkFileService; | 9 | use Shaarli\Bookmark\BookmarkFileService; |
@@ -47,6 +48,7 @@ class FeedBuilderTest extends TestCase | |||
47 | */ | 48 | */ |
48 | public static function setUpBeforeClass(): void | 49 | public static function setUpBeforeClass(): void |
49 | { | 50 | { |
51 | $mutex = new NoMutex(); | ||
50 | $conf = new ConfigManager('tests/utils/config/configJson'); | 52 | $conf = new ConfigManager('tests/utils/config/configJson'); |
51 | $conf->set('resource.datastore', self::$testDatastore); | 53 | $conf->set('resource.datastore', self::$testDatastore); |
52 | $refLinkDB = new \ReferenceLinkDB(); | 54 | $refLinkDB = new \ReferenceLinkDB(); |
@@ -54,7 +56,7 @@ class FeedBuilderTest extends TestCase | |||
54 | $history = new History('sandbox/history.php'); | 56 | $history = new History('sandbox/history.php'); |
55 | $factory = new FormatterFactory($conf, true); | 57 | $factory = new FormatterFactory($conf, true); |
56 | self::$formatter = $factory->getFormatter(); | 58 | self::$formatter = $factory->getFormatter(); |
57 | self::$bookmarkService = new BookmarkFileService($conf, $history, true); | 59 | self::$bookmarkService = new BookmarkFileService($conf, $history, $mutex, true); |
58 | 60 | ||
59 | self::$serverInfo = array( | 61 | self::$serverInfo = array( |
60 | 'HTTPS' => 'Off', | 62 | 'HTTPS' => 'Off', |