Browse Source

[Test] Sigh, just wait...

tags/2.0
Vsevolod Stakhov 4 years ago
parent
commit
2ec42fe11c
2 changed files with 9 additions and 1 deletions
  1. 8
    1
      lualib/lua_redis.lua
  2. 1
    0
      test/functional/cases/330_neural.robot

+ 8
- 1
lualib/lua_redis.lua View File

@@ -1299,7 +1299,14 @@ local function exec_redis_script(id, params, callback, keys, args)
table.insert(script.waitq, do_call)
else
-- TODO: fix taskfull requests
callback('NOSCRIPT', nil)
table.insert(script.waitq, function()
if script.loaded then
do_call(false)
else
callback('NOSCRIPT', nil)
end
end)
load_script_task(script, params.task)
end
end


+ 1
- 0
test/functional/cases/330_neural.robot View File

@@ -15,6 +15,7 @@ ${RSPAMD_SCOPE} Suite

*** Test Cases ***
Train Spam
Sleep 2s Wait for redis mess
: FOR ${INDEX} IN RANGE 0 10
\ ${result} = Scan Message With Rspamc ${MESSAGE} --header Settings={symbols_enabled = ["SPAM_SYMBOL"]}
\ Check Rspamc ${result} SPAM_SYMBOL (1.00)

Loading…
Cancel
Save