From ec945dcfb3116421ba196476355c364f1405617d Mon Sep 17 00:00:00 2001 From: Oliver Schneider Date: Sun, 27 Feb 2022 01:07:42 +0000 Subject: Trying to align output better with vanilla VS output Added tests for some VS versions that weren't currently tested --HG-- branch : WDS-build --- tests/actions/vstudio/cs2005/buildevents.lua | 53 ++++++++++++++++++++++++++++ tests/actions/vstudio/vc200x/header.lua | 21 +++++++++++ tests/premake4.lua | 1 + 3 files changed, 75 insertions(+) create mode 100644 tests/actions/vstudio/cs2005/buildevents.lua (limited to 'tests') diff --git a/tests/actions/vstudio/cs2005/buildevents.lua b/tests/actions/vstudio/cs2005/buildevents.lua new file mode 100644 index 0000000..213de1b --- /dev/null +++ b/tests/actions/vstudio/cs2005/buildevents.lua @@ -0,0 +1,53 @@ +-- +-- tests/actions/vstudio/cs2005/buildevents.lua +-- Validate the build events in Visual Studio 2005+ .csproj +-- Copyright (c) 2009-2014 Jason Perkins and the Premake project +-- + + T.vstudio_cs2005_buildevents = { } + local suite = T.vstudio_cs2005_buildevents + local cs2005 = premake.vstudio.cs2005 + +-- +-- Setup +-- + + local sln, prj + + function suite.setup() + sln = test.createsolution() + end + + local function prepare() + premake.bake.buildconfigs() + prj = premake.solution.getproject(sln, 1) + cs2005.buildevents(prj) + end + +-- +-- Prebuild events +-- + + function suite.prebuildEvents() + prebuildcommands { "pre" } + prepare() + test.capture [[ + + pre + + ]] + end + +-- +-- Postbuild events +-- + + function suite.postbuildEvents() + postbuildcommands { "post" } + prepare() + test.capture [[ + + post + + ]] + end diff --git a/tests/actions/vstudio/vc200x/header.lua b/tests/actions/vstudio/vc200x/header.lua index 18670ec..cde6570 100644 --- a/tests/actions/vstudio/vc200x/header.lua +++ b/tests/actions/vstudio/vc200x/header.lua @@ -42,6 +42,27 @@ ]] end + function suite.On2003() + _ACTION = 'vs2003' + prepare() + test.capture [[ + + +