blob: a82ccdf8d50df7e7f515f2067678d889779082a5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
--
-- tests/premake4.lua
-- Automated test suite for Premake 4.x
-- Copyright (c) 2008, 2009 Jason Perkins and the Premake project
--
dofile("testfx.lua")
dofile("test_dofile.lua")
dofile("test_os.lua")
dofile("test_path.lua")
dofile("test_string.lua")
dofile("test_table.lua")
dofile("test_premake.lua")
dofile("test_project.lua")
dofile("test_configs.lua")
dofile("test_platforms.lua")
dofile("test_api.lua")
dofile("test_targets.lua")
dofile("test_keywords.lua")
dofile("test_gcc.lua")
dofile("test_vs2002_sln.lua")
dofile("test_vs2003_sln.lua")
dofile("test_vs2005_sln.lua")
dofile("test_vs2008_sln.lua")
dofile("test_vs200x_vcproj.lua")
dofile("test_gmake_cpp.lua")
--
-- Register a test action
--
premake.actions["test"] = {
description = "Run the automated test suite",
execute = function ()
passed, failed = test.runall()
msg = string.format("%d tests passed, %d failed", passed, failed)
if (failed > 0) then
error(msg, 0)
else
print(msg)
end
end
}
|