Mercurial > prosody-hg
comparison spec/util_jwt_spec.lua @ 10661:4eee1aaa9405
util.jwt: Remove unused return value from tests [luacheck]
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Mon, 24 Feb 2020 09:10:28 +0100 |
| parents | c4ded3be7cc0 |
| children | 27a72982e331 |
comparison
equal
deleted
inserted
replaced
| 10660:c4ded3be7cc0 | 10661:4eee1aaa9405 |
|---|---|
| 11 end); | 11 end); |
| 12 it("rejects invalid", function () | 12 it("rejects invalid", function () |
| 13 local key = "secret"; | 13 local key = "secret"; |
| 14 local token = jwt.sign("wrong", { payload = "this" }); | 14 local token = jwt.sign("wrong", { payload = "this" }); |
| 15 assert.string(token); | 15 assert.string(token); |
| 16 local ok, err = jwt.verify(key, token); | 16 local ok = jwt.verify(key, token); |
| 17 assert.falsy(ok) | 17 assert.falsy(ok) |
| 18 end); | 18 end); |
| 19 end); | 19 end); |
| 20 | 20 |
