2008-12-18 17:53:57 +00:00
|
|
|
--
|
|
|
|
-- tests/test_keywords.lua
|
|
|
|
-- Automated test suite for configuration block keyword filtering.
|
2009-12-22 16:07:55 +00:00
|
|
|
-- Copyright (c) 2008, 2009 Jason Perkins and the Premake project
|
2008-12-18 17:53:57 +00:00
|
|
|
--
|
|
|
|
|
|
|
|
T.keywords = { }
|
2009-12-22 16:07:55 +00:00
|
|
|
local suite = T.keywords
|
2008-12-18 17:53:57 +00:00
|
|
|
|
|
|
|
|
|
|
|
--
|
|
|
|
-- Keyword matching tests
|
2012-01-20 00:14:18 +00:00
|
|
|
--
|
2008-12-18 17:53:57 +00:00
|
|
|
|
|
|
|
|
|
|
|
function T.keywords.match_ok_required_term()
|
|
|
|
test.istrue(premake.iskeywordsmatch({ "debug", "hello.c" }, { "debug", "windows", "vs2005", required="hello.c" }))
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
function T.keywords.match_fail_required_term()
|
|
|
|
test.isfalse(premake.iskeywordsmatch({ "debug" }, { "debug", "windows", "vs2005", required="hello.c" }))
|
|
|
|
end
|