mirror of
https://github.com/nmap/nmap.git
synced 2025-12-06 12:41:29 +00:00
Add unittest.testing() to make test building conditional
This commit is contained in:
@@ -396,6 +396,10 @@ function utf8to16(from)
|
||||
return table.concat(buf)
|
||||
end
|
||||
|
||||
if not unittest.testing() then
|
||||
return _ENV
|
||||
end
|
||||
|
||||
test_suite = unittest.TestSuite:new()
|
||||
test_suite:add_test(function()
|
||||
local pos, cp = utf8_dec("\xE6\x97\xA5\xE6\x9C\xAC\xE8\xAA\x9E")
|
||||
|
||||
Reference in New Issue
Block a user