Fixed inconsistencies in Android VS project test

This commit is contained in:
Sam Surtees 2019-11-07 02:34:38 +10:00
parent bd70a11d1c
commit 448fb5c697

View File

@ -12,26 +12,25 @@
function suite.setup() function suite.setup()
p.action.set("vs2015") p.action.set("vs2015")
system "android"
wks, prj = test.createWorkspace() wks, prj = test.createWorkspace()
end end
local function prepare() local function prepare()
system "android" local cfg = test.getconfig(prj, "Debug")
local cfg = test.getconfig(prj, "Debug", platform)
vc2010.clCompile(cfg) vc2010.clCompile(cfg)
end end
local function preparePropertyGroup() local function prepareGlobals()
system "android" prj = test.getproject(wks, 1)
local cfg = test.getconfig(prj, "Debug", platform) vc2010.globals(prj)
vc2010.propertyGroup(cfg)
android.androidApplicationType(cfg)
end end
function suite.minVisualStudioVersion_14() function suite.minVisualStudioVersion_14()
preparePropertyGroup() prepareGlobals()
test.capture [[ test.capture [[
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Android'"> <PropertyGroup Label="Globals">
<ProjectGuid>{42B5DBC6-AE1F-903D-F75D-41E363076E92}</ProjectGuid>
<Keyword>Android</Keyword> <Keyword>Android</Keyword>
<RootNamespace>MyProject</RootNamespace> <RootNamespace>MyProject</RootNamespace>
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion> <MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>
@ -41,9 +40,10 @@
function suite.minVisualStudioVersion_15() function suite.minVisualStudioVersion_15()
p.action.set("vs2017") p.action.set("vs2017")
preparePropertyGroup() prepareGlobals()
test.capture [[ test.capture [[
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Android'"> <PropertyGroup Label="Globals">
<ProjectGuid>{42B5DBC6-AE1F-903D-F75D-41E363076E92}</ProjectGuid>
<Keyword>Android</Keyword> <Keyword>Android</Keyword>
<RootNamespace>MyProject</RootNamespace> <RootNamespace>MyProject</RootNamespace>
<MinimumVisualStudioVersion>15.0</MinimumVisualStudioVersion> <MinimumVisualStudioVersion>15.0</MinimumVisualStudioVersion>
@ -53,9 +53,10 @@
function suite.minVisualStudioVersion_16() function suite.minVisualStudioVersion_16()
p.action.set("vs2019") p.action.set("vs2019")
preparePropertyGroup() prepareGlobals()
test.capture [[ test.capture [[
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Android'"> <PropertyGroup Label="Globals">
<ProjectGuid>{42B5DBC6-AE1F-903D-F75D-41E363076E92}</ProjectGuid>
<Keyword>Android</Keyword> <Keyword>Android</Keyword>
<RootNamespace>MyProject</RootNamespace> <RootNamespace>MyProject</RootNamespace>
<MinimumVisualStudioVersion>16.0</MinimumVisualStudioVersion> <MinimumVisualStudioVersion>16.0</MinimumVisualStudioVersion>