2011-02-16 20:16:07 +00:00
|
|
|
--
|
|
|
|
-- tests/actions/vstudio/cs2005/projectsettings.lua
|
|
|
|
-- Validate generation of root <PropertyGroup/> in Visual Studio 2005+ .csproj
|
2012-07-10 20:44:44 +00:00
|
|
|
-- Copyright (c) 2009-2012 Jason Perkins and the Premake project
|
2011-02-16 20:16:07 +00:00
|
|
|
--
|
|
|
|
|
|
|
|
T.vstudio_cs2005_projectsettings = { }
|
|
|
|
local suite = T.vstudio_cs2005_projectsettings
|
|
|
|
local cs2005 = premake.vstudio.cs2005
|
|
|
|
|
|
|
|
|
|
|
|
--
|
|
|
|
-- Setup
|
|
|
|
--
|
|
|
|
|
|
|
|
local sln, prj
|
|
|
|
|
|
|
|
function suite.setup()
|
2012-07-10 20:44:44 +00:00
|
|
|
sln, prj = test.createsolution()
|
2011-02-16 20:16:07 +00:00
|
|
|
language "C#"
|
|
|
|
uuid "AE61726D-187C-E440-BD07-2556188A6565"
|
|
|
|
end
|
|
|
|
|
|
|
|
local function prepare()
|
|
|
|
cs2005.projectsettings(prj)
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
--
|
|
|
|
-- Version Tests
|
|
|
|
--
|
|
|
|
|
|
|
|
function suite.OnVs2005()
|
|
|
|
_ACTION = "vs2005"
|
|
|
|
prepare()
|
|
|
|
test.capture [[
|
2012-07-10 20:44:44 +00:00
|
|
|
<PropertyGroup>
|
|
|
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
|
|
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
|
|
|
<ProductVersion>8.0.50727</ProductVersion>
|
|
|
|
<SchemaVersion>2.0</SchemaVersion>
|
|
|
|
<ProjectGuid>{AE61726D-187C-E440-BD07-2556188A6565}</ProjectGuid>
|
|
|
|
<OutputType>Exe</OutputType>
|
|
|
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
|
|
|
<RootNamespace>MyProject</RootNamespace>
|
|
|
|
<AssemblyName>MyProject</AssemblyName>
|
|
|
|
</PropertyGroup>
|
2011-02-16 20:16:07 +00:00
|
|
|
]]
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
function suite.OnVs2008()
|
|
|
|
_ACTION = "vs2008"
|
|
|
|
prepare()
|
|
|
|
test.capture [[
|
2012-07-10 20:44:44 +00:00
|
|
|
<PropertyGroup>
|
|
|
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
|
|
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
|
|
|
<ProductVersion>9.0.21022</ProductVersion>
|
|
|
|
<SchemaVersion>2.0</SchemaVersion>
|
|
|
|
<ProjectGuid>{AE61726D-187C-E440-BD07-2556188A6565}</ProjectGuid>
|
|
|
|
<OutputType>Exe</OutputType>
|
|
|
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
|
|
|
<RootNamespace>MyProject</RootNamespace>
|
|
|
|
<AssemblyName>MyProject</AssemblyName>
|
|
|
|
</PropertyGroup>
|
2011-02-16 20:16:07 +00:00
|
|
|
]]
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
function suite.OnVs2010()
|
|
|
|
_ACTION = "vs2010"
|
|
|
|
prepare()
|
|
|
|
test.capture [[
|
2012-07-10 20:44:44 +00:00
|
|
|
<PropertyGroup>
|
|
|
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
|
|
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
|
|
|
<ProductVersion>8.0.30703</ProductVersion>
|
|
|
|
<SchemaVersion>2.0</SchemaVersion>
|
|
|
|
<ProjectGuid>{AE61726D-187C-E440-BD07-2556188A6565}</ProjectGuid>
|
|
|
|
<OutputType>Exe</OutputType>
|
|
|
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
|
|
|
<RootNamespace>MyProject</RootNamespace>
|
|
|
|
<AssemblyName>MyProject</AssemblyName>
|
|
|
|
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
|
|
|
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
|
|
|
|
<FileAlignment>512</FileAlignment>
|
|
|
|
</PropertyGroup>
|
2011-02-16 20:16:07 +00:00
|
|
|
]]
|
|
|
|
end
|
|
|
|
|
|
|
|
|
2012-06-08 19:07:49 +00:00
|
|
|
function suite.OnVs2012()
|
|
|
|
_ACTION = "vs2012"
|
|
|
|
prepare()
|
|
|
|
test.capture [[
|
2012-07-10 20:44:44 +00:00
|
|
|
<PropertyGroup>
|
|
|
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
|
|
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
|
|
|
<ProductVersion>8.0.30703</ProductVersion>
|
|
|
|
<SchemaVersion>2.0</SchemaVersion>
|
|
|
|
<ProjectGuid>{AE61726D-187C-E440-BD07-2556188A6565}</ProjectGuid>
|
|
|
|
<OutputType>Exe</OutputType>
|
|
|
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
|
|
|
<RootNamespace>MyProject</RootNamespace>
|
|
|
|
<AssemblyName>MyProject</AssemblyName>
|
|
|
|
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
|
|
|
|
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
|
|
|
|
<FileAlignment>512</FileAlignment>
|
|
|
|
</PropertyGroup>
|
2012-06-08 19:07:49 +00:00
|
|
|
]]
|
|
|
|
end
|
|
|
|
|
2011-02-16 20:16:07 +00:00
|
|
|
|
|
|
|
--
|
|
|
|
-- Framework Tests
|
|
|
|
--
|
|
|
|
|
|
|
|
function suite.OnFrameworkVersion()
|
|
|
|
_ACTION = "vs2005"
|
|
|
|
framework "3.0"
|
|
|
|
prepare()
|
|
|
|
test.capture [[
|
2012-07-10 20:44:44 +00:00
|
|
|
<PropertyGroup>
|
|
|
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
|
|
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
|
|
|
<ProductVersion>8.0.50727</ProductVersion>
|
|
|
|
<SchemaVersion>2.0</SchemaVersion>
|
|
|
|
<ProjectGuid>{AE61726D-187C-E440-BD07-2556188A6565}</ProjectGuid>
|
|
|
|
<OutputType>Exe</OutputType>
|
|
|
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
|
|
|
<RootNamespace>MyProject</RootNamespace>
|
|
|
|
<AssemblyName>MyProject</AssemblyName>
|
|
|
|
<TargetFrameworkVersion>v3.0</TargetFrameworkVersion>
|
|
|
|
</PropertyGroup>
|
2011-02-16 20:16:07 +00:00
|
|
|
]]
|
|
|
|
end
|
|
|
|
|
|
|
|
|