From 0375c9866c12b9698e60ac021aae7de591dc7d57 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Mon, 17 Apr 2023 16:18:48 +0200 Subject: add test to verify redis lua script hashes Signed-off-by: Robin Appelman --- tests/lib/Memcache/RedisTest.php | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'tests') diff --git a/tests/lib/Memcache/RedisTest.php b/tests/lib/Memcache/RedisTest.php index 276dbf3a550..9e40698ec06 100644 --- a/tests/lib/Memcache/RedisTest.php +++ b/tests/lib/Memcache/RedisTest.php @@ -9,6 +9,8 @@ namespace Test\Memcache; +use const OC\Memcache\LUA_SCRIPTS; + /** * @group Memcache * @group Redis @@ -56,4 +58,10 @@ class RedisTest extends Cache { parent::setUp(); $this->instance = new \OC\Memcache\Redis($this->getUniqueID()); } + + public function testScriptHashes() { + foreach (LUA_SCRIPTS as $script) { + $this->assertEquals(sha1($script[0]), $script[1]); + } + } } -- cgit v1.2.3