summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/FileAPI
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2018-11-01 14:37:53 (GMT)
committerBrad King <brad.king@kitware.com>2018-12-12 11:40:10 (GMT)
commitb83fe27d8d3f25ed6e229270966b8323f5fc3ae5 (patch)
treeec345eec5c2d84087dabff361888d463d7ce41d0 /Tests/RunCMake/FileAPI
parent7ee0abbde1656b07eb28ddacca3d22bb7aafdbd8 (diff)
downloadCMake-b83fe27d8d3f25ed6e229270966b8323f5fc3ae5.zip
CMake-b83fe27d8d3f25ed6e229270966b8323f5fc3ae5.tar.gz
CMake-b83fe27d8d3f25ed6e229270966b8323f5fc3ae5.tar.bz2
fileapi: Report cmake generator in reply index file
Diffstat (limited to 'Tests/RunCMake/FileAPI')
-rw-r--r--Tests/RunCMake/FileAPI/check_index.py13
1 files changed, 12 insertions, 1 deletions
diff --git a/Tests/RunCMake/FileAPI/check_index.py b/Tests/RunCMake/FileAPI/check_index.py
index 4d90d59..d8eaecb 100644
--- a/Tests/RunCMake/FileAPI/check_index.py
+++ b/Tests/RunCMake/FileAPI/check_index.py
@@ -23,9 +23,10 @@ def is_string(x):
def check_cmake(cmake):
assert is_dict(cmake)
- assert sorted(cmake.keys()) == ["paths", "version"]
+ assert sorted(cmake.keys()) == ["generator", "paths", "version"]
check_cmake_version(cmake["version"])
check_cmake_paths(cmake["paths"])
+ check_cmake_generator(cmake["generator"])
def check_cmake_version(v):
assert is_dict(v)
@@ -45,6 +46,16 @@ def check_cmake_paths(v):
assert is_string(v["ctest"])
assert is_string(v["root"])
+def check_cmake_generator(g):
+ assert is_dict(g)
+ name = g.get("name", None)
+ assert is_string(name)
+ if name.startswith("Visual Studio"):
+ assert sorted(g.keys()) == ["name", "platform"]
+ assert is_string(g["platform"])
+ else:
+ assert sorted(g.keys()) == ["name"]
+
def check_index_object(indexEntry, kind, major, minor, check):
assert is_dict(indexEntry)
assert sorted(indexEntry.keys()) == ["jsonFile", "kind", "version"]