Finish renaming architectures away from x32/x64

A number of tests were relying on the fact that x32/x64 were being converted implicitly to x86/x86_64. If/when we retire those symbols, all of those tests would break. Renamed them now to avoid having to sort it out later. Also fixed up comments to keep everything consistent.
This commit is contained in:
Jason Perkins 2015-04-13 18:27:11 -04:00
parent 545b2901f0
commit 17f1843c71
16 changed files with 60 additions and 60 deletions

@ -1 +1 @@
Subproject commit 897ad816714576a611d6d02c99e55a82954c5bbf Subproject commit b0f33f4c9fd5ad54adceb23e0caa7362cd6d5ac3

View File

@ -756,7 +756,7 @@
if not cfg.editAndContinue or if not cfg.editAndContinue or
config.isOptimizedBuild(cfg) or config.isOptimizedBuild(cfg) or
cfg.clr ~= p.OFF or cfg.clr ~= p.OFF or
cfg.system == "x64" cfg.architecture == p.X86_64
then then
return 3 return 3
else else

View File

@ -43,7 +43,7 @@
-- --
-- Returns an iterator function for the configuration objects contained by -- Returns an iterator function for the configuration objects contained by
-- the project. Each configuration corresponds to a build configuration/ -- the project. Each configuration corresponds to a build configuration/
-- platform pair (i.e. "Debug|x32") as specified in the solution. -- platform pair (i.e. "Debug|x86") as specified in the solution.
-- --
-- @param prj -- @param prj
-- The project object to query. -- The project object to query.

View File

@ -71,7 +71,7 @@
]] ]]
end end
function suite.onX32() function suite.onX86()
prepare("x86") prepare("x86")
test.capture [[ test.capture [[
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
@ -80,7 +80,7 @@
end end
function suite.onX64() function suite.onX86_64()
prepare("x86_64") prepare("x86_64")
test.capture [[ test.capture [[
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x64' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x64' ">

View File

@ -289,7 +289,7 @@
-- Use the right variant for 32-bit architectures. -- Use the right variant for 32-bit architectures.
-- --
function suite.onSingleCpp_noPlatforms_x32() function suite.onSingleCpp_noPlatforms_x86()
architecture "x86" architecture "x86"
project "MyProject" project "MyProject"
prepare() prepare()
@ -307,7 +307,7 @@
]] ]]
end end
function suite.onSingleCs_noPlatforms_x32() function suite.onSingleCs_noPlatforms_x86()
architecture "x86" architecture "x86"
project "MyProject" project "MyProject"
language "C#" language "C#"
@ -326,7 +326,7 @@
]] ]]
end end
function suite.onMixedLanguage_noPlatforms_x32() function suite.onMixedLanguage_noPlatforms_x86()
architecture "x86" architecture "x86"
project "MyProject1" project "MyProject1"
@ -465,7 +465,7 @@
-- --
function suite.onSingleCpp_withPlatformsMatchingArch_noArchs() function suite.onSingleCpp_withPlatformsMatchingArch_noArchs()
platforms { "x32", "Xbox360" } platforms { "x86", "Xbox360" }
project "MyProject" project "MyProject"
prepare() prepare()
test.capture [[ test.capture [[
@ -489,7 +489,7 @@
end end
function suite.onSingleCs_withPlatformsMatchingArch_noArchs() function suite.onSingleCs_withPlatformsMatchingArch_noArchs()
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
project "MyProject" project "MyProject"
language "C#" language "C#"
prepare() prepare()
@ -514,7 +514,7 @@
end end
function suite.onMixedLanguage_withPlatformsMatchingArch_noArchs() function suite.onMixedLanguage_withPlatformsMatchingArch_noArchs()
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
project "MyProject1" project "MyProject1"
language "C#" language "C#"
uuid "52AD9329-0D74-4F66-A213-E649D8CCD737" uuid "52AD9329-0D74-4F66-A213-E649D8CCD737"
@ -795,8 +795,8 @@
--- ---
function suite.onDefaultPlatforms() function suite.onDefaultPlatforms()
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
defaultplatform "x64" defaultplatform "x86_64"
project "MyProject" project "MyProject"
prepare() prepare()
test.capture [[ test.capture [[

View File

@ -50,9 +50,9 @@
-- If a platform is specified, it should be included in the platform name. -- If a platform is specified, it should be included in the platform name.
-- --
function suite.usesWin32_onX32() function suite.usesWin32_onX86()
solution "MySolution" solution "MySolution"
platforms { "x32" } platforms { "x86" }
prepare() prepare()
test.capture [[ test.capture [[
<Configuration <Configuration
@ -65,8 +65,8 @@
-- Check the x64 architecture handling. -- Check the x64 architecture handling.
-- --
function suite.usesX64Architecture_onX64Platform() function suite.usesX64Architecture_onX86_64Platform()
platforms { "x64" } platforms { "x86_64" }
prepare() prepare()
test.capture [[ test.capture [[
<Configuration <Configuration

View File

@ -65,7 +65,7 @@
-- --
function suite.allArchitecturesListed_onMultipleArchitectures() function suite.allArchitecturesListed_onMultipleArchitectures()
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
prepare() prepare()
test.capture [[ test.capture [[
<Platforms> <Platforms>

View File

@ -88,7 +88,7 @@
-- --
function suite.allArchitecturesListed_onImplicitArchitectures() function suite.allArchitecturesListed_onImplicitArchitectures()
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
prepare() prepare()
test.capture [[ test.capture [[
<ItemGroup Label="ProjectConfigurations"> <ItemGroup Label="ProjectConfigurations">

View File

@ -31,7 +31,7 @@
-- --
function suite.matches_fails_onMissingContext() function suite.matches_fails_onMissingContext()
crit = criteria.new { "system:Windows", "architecture:x32" } crit = criteria.new { "system:Windows", "architecture:x86" }
test.isfalse(criteria.matches(crit, { configurations="Debug", system="Windows" })) test.isfalse(criteria.matches(crit, { configurations="Debug", system="Windows" }))
end end

View File

@ -47,10 +47,10 @@
function suite.singleProject_withPlatforms() function suite.singleProject_withPlatforms()
sln = solution "MySolution" sln = solution "MySolution"
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
prj = project "MyProject" prj = project "MyProject"
test.isequal("obj/x32/Debug", result("Debug", "x32")) test.isequal("obj/x86/Debug", result("Debug", "x86"))
end end
@ -67,20 +67,20 @@
function suite.singleProject_uniqueByTokens_withPlatforms() function suite.singleProject_uniqueByTokens_withPlatforms()
sln = solution "MySolution" sln = solution "MySolution"
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
prj = project "MyProject" prj = project "MyProject"
objdir "obj/%{cfg.buildcfg}_%{cfg.platform}" objdir "obj/%{cfg.buildcfg}_%{cfg.platform}"
test.isequal("obj/Debug_x32", result("Debug", "x32")) test.isequal("obj/Debug_x86", result("Debug", "x86"))
end end
function suite.allowOverlap_onPrefixCode() function suite.allowOverlap_onPrefixCode()
sln = solution "MySolution" sln = solution "MySolution"
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
prj = project "MyProject" prj = project "MyProject"
objdir "!obj/%{cfg.buildcfg}" objdir "!obj/%{cfg.buildcfg}"
test.isequal("obj/Debug", result("Debug", "x32")) test.isequal("obj/Debug", result("Debug", "x86"))
end end

View File

@ -133,16 +133,16 @@
removeconfigurations "*" removeconfigurations "*"
removeplatforms "*" removeplatforms "*"
configurations { "Development", "Production" } configurations { "Development", "Production" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
configmap { configmap {
[{"Debug", "Win32"}] = { "Development", "x32" }, [{"Debug", "Win32"}] = { "Development", "x86" },
[{"Debug", "Linux"}] = { "Development", "x64" }, [{"Debug", "Linux"}] = { "Development", "x86_64" },
[{"Release", "Win32"}] = { "Production", "x32" }, [{"Release", "Win32"}] = { "Production", "x86" },
[{"Release", "Linux"}] = { "Production", "x64" }, [{"Release", "Linux"}] = { "Production", "x86_64" },
} }
prepare("Debug", "Linux") prepare("Debug", "Linux")
test.isequal({ "Development", "x64" }, { cfg.buildcfg, cfg.platform }) test.isequal({ "Development", "x86_64" }, { cfg.buildcfg, cfg.platform })
end end

View File

@ -47,7 +47,7 @@
-- --
function suite.returnsNoValues_onNoConfigurationsButPlatforms() function suite.returnsNoValues_onNoConfigurationsButPlatforms()
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
prepare() prepare()
test.isemptycapture() test.isemptycapture()
end end
@ -77,13 +77,13 @@
function suite.pairsConfigsAndPlatformsInOrder() function suite.pairsConfigsAndPlatformsInOrder()
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
prepare() prepare()
test.capture [[ test.capture [[
Debug:x32 Debug:x86
Debug:x64 Debug:x86_64
Release:x32 Release:x86
Release:x64 Release:x86_64
]] ]]
end end
@ -110,11 +110,11 @@
function suite.mapsPlatform_toPlatform() function suite.mapsPlatform_toPlatform()
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
platforms { "Win32" } platforms { "Win32" }
configmap { ["Win32"] = "x64" } configmap { ["Win32"] = "x86_64" }
prepare() prepare()
test.capture [[ test.capture [[
Debug:x64 Debug:x86_64
Release:x64 Release:x86_64
]] ]]
end end
@ -128,12 +128,12 @@
function suite.mapsBuildCfg_toBuildCfgAndPlatform() function suite.mapsBuildCfg_toBuildCfgAndPlatform()
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
platforms { "Win32" } platforms { "Win32" }
configmap { ["Debug"] = { "ProjectDebug", "x64" } } configmap { ["Debug"] = { "ProjectDebug", "x86_64" } }
prepare() prepare()
test.capture [[ test.capture [[
ProjectDebug:x64 ProjectDebug:x86_64
ProjectDebug:Win32 ProjectDebug:Win32
Release:x64 Release:x86_64
Release:Win32 Release:Win32
]] ]]
end end

View File

@ -92,7 +92,7 @@
-- --
function suite.setsArchitecture_onMatchingPlatform() function suite.setsArchitecture_onMatchingPlatform()
platforms { "x86", "x64" } platforms { "x86", "x86_64" }
project ("MyProject") project ("MyProject")
prepare("Debug", "x86") prepare("Debug", "x86")
test.isequal("x86", cfg.architecture) test.isequal("x86", cfg.architecture)

View File

@ -14,7 +14,7 @@
local sln local sln
function suite.setup() function suite.setup()
sln = solution("MySolution") sln = solution("MySolution")
end end
local function prepare() local function prepare()
@ -49,15 +49,15 @@
function suite.listsInOrder_onBuildConfigsAndPlatforms() function suite.listsInOrder_onBuildConfigsAndPlatforms()
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
project("MyProject") project("MyProject")
prepare() prepare()
test.capture [[ test.capture [[
- -
Debug:x32 Debug:x86
Debug:x64 Debug:x86_64
Release:x32 Release:x86
Release:x64 Release:x86_64
- -
]] ]]
end end
@ -72,7 +72,7 @@
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
project ("MyProject") project ("MyProject")
configurations { "PrjDebug", "PrjRelease" } configurations { "PrjDebug", "PrjRelease" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
prepare() prepare()
test.capture [[ test.capture [[
- -

View File

@ -44,8 +44,8 @@
function suite.directoryIncludesPlatform_onPlatformConflict() function suite.directoryIncludesPlatform_onPlatformConflict()
configurations { "Debug" } configurations { "Debug" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
test.isequal("obj/x32", result()) test.isequal("obj/x86", result())
end end
@ -67,8 +67,8 @@
function suite.directoryIncludesBuildCfg_onPlatformAndBuildCfgConflict() function suite.directoryIncludesBuildCfg_onPlatformAndBuildCfgConflict()
configurations { "Debug", "Release" } configurations { "Debug", "Release" }
platforms { "x32", "x64" } platforms { "x86", "x86_64" }
test.isequal("obj/x32/Debug", result()) test.isequal("obj/x86/Debug", result())
end end

View File

@ -275,25 +275,25 @@
-- Make sure system or architecture flags are added properly. -- Make sure system or architecture flags are added properly.
-- --
function suite.cflags_onX32() function suite.cflags_onX86()
architecture "x86" architecture "x86"
prepare() prepare()
test.contains({ "-m32" }, gcc.getcflags(cfg)) test.contains({ "-m32" }, gcc.getcflags(cfg))
end end
function suite.ldflags_onX32() function suite.ldflags_onX86()
architecture "x86" architecture "x86"
prepare() prepare()
test.contains({ "-m32" }, gcc.getldflags(cfg)) test.contains({ "-m32" }, gcc.getldflags(cfg))
end end
function suite.cflags_onX64() function suite.cflags_onX86_64()
architecture "x86_64" architecture "x86_64"
prepare() prepare()
test.contains({ "-m64" }, gcc.getcflags(cfg)) test.contains({ "-m64" }, gcc.getcflags(cfg))
end end
function suite.ldflags_onX64() function suite.ldflags_onX86_64()
architecture "x86_64" architecture "x86_64"
prepare() prepare()
test.contains({ "-m64" }, gcc.getldflags(cfg)) test.contains({ "-m64" }, gcc.getldflags(cfg))