Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/windirstat/premake-4.x-stable.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/actions/make/test_make_pch.lua17
-rwxr-xr-xtests/actions/vstudio/cs2005/projectelement.lua9
-rwxr-xr-xtests/actions/vstudio/sln2005/header.lua10
-rw-r--r--tests/actions/vstudio/vc2010/test_config_props.lua13
-rw-r--r--tests/test_gmake_cpp.lua6
5 files changed, 52 insertions, 3 deletions
diff --git a/tests/actions/make/test_make_pch.lua b/tests/actions/make/test_make_pch.lua
index 75d9d9d..4664661 100644
--- a/tests/actions/make/test_make_pch.lua
+++ b/tests/actions/make/test_make_pch.lua
@@ -85,6 +85,7 @@ $(GCH): $(PCH)
]]
end
+
--
-- Ensure that PCH is included on all files that use it.
--
@@ -101,3 +102,19 @@ $(OBJDIR)/main.o: main.cpp
]]
end
+
+--
+-- If the header is located on one of the include file
+-- search directories, it should get found automatically.
+--
+
+ function suite.findsPCH_onIncludeDirs()
+ location "MyProject"
+ pchheader "premake.h"
+ includedirs { "../src/host" }
+ prepare()
+ _.pchconfig(cfg)
+ test.capture [[
+ PCH = ../../src/host/premake.h
+ ]]
+ end
diff --git a/tests/actions/vstudio/cs2005/projectelement.lua b/tests/actions/vstudio/cs2005/projectelement.lua
index 1d2a61f..5825abc 100755
--- a/tests/actions/vstudio/cs2005/projectelement.lua
+++ b/tests/actions/vstudio/cs2005/projectelement.lua
@@ -63,3 +63,12 @@
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
]]
end
+
+ function suite.On2013()
+ _ACTION = "vs2013"
+ prepare()
+ test.capture [[
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ ]]
+ end
diff --git a/tests/actions/vstudio/sln2005/header.lua b/tests/actions/vstudio/sln2005/header.lua
index 5eb02e3..71e32f5 100755
--- a/tests/actions/vstudio/sln2005/header.lua
+++ b/tests/actions/vstudio/sln2005/header.lua
@@ -67,3 +67,13 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
]]
end
+
+
+ function suite.On2013()
+ _ACTION = "vs2013"
+ prepare()
+ test.capture [[
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio 2013
+ ]]
+ end
diff --git a/tests/actions/vstudio/vc2010/test_config_props.lua b/tests/actions/vstudio/vc2010/test_config_props.lua
index 3aef357..50d78ae 100644
--- a/tests/actions/vstudio/vc2010/test_config_props.lua
+++ b/tests/actions/vstudio/vc2010/test_config_props.lua
@@ -63,3 +63,16 @@
</PropertyGroup>
]]
end
+
+ function suite.structureIsCorrect_onDefaultValues_on2013()
+ _ACTION = "vs2013"
+ prepare()
+ test.capture [[
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
+ <ConfigurationType>Application</ConfigurationType>
+ <UseDebugLibraries>true</UseDebugLibraries>
+ <CharacterSet>MultiByte</CharacterSet>
+ <PlatformToolset>v120</PlatformToolset>
+ </PropertyGroup>
+ ]]
+ end
diff --git a/tests/test_gmake_cpp.lua b/tests/test_gmake_cpp.lua
index 2844567..dde8033 100644
--- a/tests/test_gmake_cpp.lua
+++ b/tests/test_gmake_cpp.lua
@@ -85,7 +85,7 @@ ifeq ($(config),debug)
ALL_LDFLAGS += $(LDFLAGS) -s
LDDEPS +=
LIBS += $(LDDEPS)
- LINKCMD = $(CXX) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ARCH) $(LIBS) $(ALL_LDFLAGS)
+ LINKCMD = $(CXX) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ARCH) $(ALL_LDFLAGS) $(LIBS)
define PREBUILDCMDS
endef
define PRELINKCMDS
@@ -119,7 +119,7 @@ ifeq ($(config),debugps3)
ALL_LDFLAGS += $(LDFLAGS) -s
LDDEPS +=
LIBS += $(LDDEPS)
- LINKCMD = $(CXX) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ARCH) $(LIBS) $(ALL_LDFLAGS)
+ LINKCMD = $(CXX) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ARCH) $(ALL_LDFLAGS) $(LIBS)
define PREBUILDCMDS
endef
define PRELINKCMDS
@@ -150,7 +150,7 @@ ifeq ($(config),debug64)
ALL_LDFLAGS += $(LDFLAGS) -s -m64 -L/usr/lib64
LDDEPS +=
LIBS += $(LDDEPS)
- LINKCMD = $(CXX) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ARCH) $(LIBS) $(ALL_LDFLAGS)
+ LINKCMD = $(CXX) -o $(TARGET) $(OBJECTS) $(RESOURCES) $(ARCH) $(ALL_LDFLAGS) $(LIBS)
define PREBUILDCMDS
endef
define PRELINKCMDS