diff options
Diffstat (limited to 'test/lua')
-rw-r--r-- | test/lua/unit/addr.lua | 4 | ||||
-rw-r--r-- | test/lua/unit/url.lua | 3 |
2 files changed, 6 insertions, 1 deletions
diff --git a/test/lua/unit/addr.lua b/test/lua/unit/addr.lua index 6ec058c3f..03ceb2dbd 100644 --- a/test/lua/unit/addr.lua +++ b/test/lua/unit/addr.lua @@ -2,7 +2,7 @@ context("Inet addr check functions", function() local ffi = require("ffi") - + ffi.cdef[[ typedef struct rspamd_inet_addr_s rspamd_inet_addr_t; bool rspamd_parse_inet_address (rspamd_inet_addr_t **target, @@ -16,6 +16,8 @@ context("Inet addr check functions", function() {'256.1.1.1', false}, {'/tmp/socket', true}, {'./socket', true}, + {'[fe80::f919:8b26:ff93:3092%5]', true}, + {'[fe80::f919:8b26:ff93:3092]', true}, } for i,c in ipairs(cases) do diff --git a/test/lua/unit/url.lua b/test/lua/unit/url.lua index ccde222f8..902744c2e 100644 --- a/test/lua/unit/url.lua +++ b/test/lua/unit/url.lua @@ -95,6 +95,9 @@ context("URL check functions", function() {"http://twitter.com#test", true, { host = 'twitter.com', fragment = 'test' }}, + {"http:www.twitter.com#test", true, { + host = 'www.twitter.com', fragment = 'test' + }}, } -- Some cases from https://code.google.com/p/google-url/source/browse/trunk/src/url_canon_unittest.cc |