aboutsummaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2020-03-11 16:29:57 +0000
committerMatthew Wild <mwild1@gmail.com>2020-03-11 16:29:57 +0000
commit81f5c3e319792bec5d53c30334f3f54537aeb32b (patch)
tree7730ad7cccd994ed8c798b9efb66cd997347078e /spec
parente35a4db4984013d82c90bd99fa1cbb15396fa415 (diff)
downloadprosody-81f5c3e319792bec5d53c30334f3f54537aeb32b.tar.gz
prosody-81f5c3e319792bec5d53c30334f3f54537aeb32b.zip
storagemanager: Add support for :find_key() and :delete_key() to map store shim
Diffstat (limited to 'spec')
-rw-r--r--spec/core_storagemanager_spec.lua11
1 files changed, 4 insertions, 7 deletions
diff --git a/spec/core_storagemanager_spec.lua b/spec/core_storagemanager_spec.lua
index dd80f4b8..848f7910 100644
--- a/spec/core_storagemanager_spec.lua
+++ b/spec/core_storagemanager_spec.lua
@@ -62,9 +62,6 @@ describe("storagemanager", function ()
sm.initialize_host(test_host);
assert(mm.load(test_host, "storage_"..backend_config.storage));
- local sql_it = backend_config.sql and it or pending;
-
-
describe("key-value stores", function ()
-- These tests rely on being executed in order, disable any order
-- randomization for this block
@@ -116,7 +113,7 @@ describe("storagemanager", function ()
assert.equal("bar", store:get("user9999", "foo"));
end);
- sql_it("may find all users with a specific key", function ()
+ it("may find all users with a specific key", function ()
assert.is_function(store.find_key);
assert(store:set("user9999b", "bar", "bar"));
assert(store:set("user9999c", "foo", "blah"));
@@ -125,7 +122,7 @@ describe("storagemanager", function ()
assert.same({ user9999 = "bar", user9999c = "blah" }, ret);
end);
- sql_it("rejects empty or non-string keys to find_key", function ()
+ it("rejects empty or non-string keys to find_key", function ()
assert.is_function(store.find_key);
do
local ret, err = store:find_key("");
@@ -139,7 +136,7 @@ describe("storagemanager", function ()
end
end);
- sql_it("rejects empty or non-string keys to delete_key", function ()
+ it("rejects empty or non-string keys to delete_key", function ()
assert.is_function(store.delete_key);
do
local ret, err = store:delete_key("");
@@ -153,7 +150,7 @@ describe("storagemanager", function ()
end
end);
- sql_it("may delete all instances of a specific key", function ()
+ it("may delete all instances of a specific key", function ()
assert.is_function(store.delete_key);
assert(store:set("user9999b", "foo", "hello"));