Skip to content

Commit 8289f27

Browse files
committed
Merge tests from @nadavelkabets ament#587
Co-authored-by: R. Kent James <[email protected]> Co-authored-by Nadav Elkabets <[email protected]> Signed-off-by: R Kent James <[email protected]>
1 parent ec46e6a commit 8289f27

File tree

15 files changed

+122
-11
lines changed

15 files changed

+122
-11
lines changed

ament_cmake_python_test/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ project(ament_cmake_python_test)
55
find_package(ament_cmake_core REQUIRED)
66

77
# Uncomment to debug CMake variables
8-
#
8+
#
99
#get_cmake_property(_variableNames VARIABLES)
1010
#list (SORT _variableNames)
1111
#foreach (_variableName ${_variableNames})
@@ -16,7 +16,7 @@ if(BUILD_TESTING)
1616
find_package(ament_cmake_pytest REQUIRED)
1717
find_package(ament_cmake_python REQUIRED)
1818
ament_get_python_install_dir(PYTHON_INSTALL_DIR)
19-
19+
2020
set(_pytest_tests
2121
test/build_with_colcon.py
2222
# Add other test files here

ament_cmake_python_test/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ This package exists solely to test the ament_cmake_python package.
44

55
It runs `colcon build` on some test packages, with the working directory `build/ament_cmake_package_test`.
66
That means that the normal `build`, `install`, and `log` directories are subdirectories of `build/ament_cmake_package_test`
7+
named `build_test`, `install_test`, and `log` respectively.

ament_cmake_python_test/test/COLCON_IGNORE

Whitespace-only changes.
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
cmake_minimum_required(VERSION 3.12)
2+
3+
project(ament_python_test_package)
4+
5+
find_package(ament_cmake_core REQUIRED)
6+
7+
find_package(ament_cmake_python REQUIRED)
8+
9+
ament_python_install_package(${PROJECT_NAME})
10+
11+
ament_package()

ament_cmake_python_test/test/ament_python_test_package/ament_python_test_package/__init__.py

Whitespace-only changes.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
class Bar:
2+
def __init__() -> None:
3+
pass
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<?xml version="1.0"?>
2+
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
3+
<package format="3">
4+
<name>ament_python_test_package</name>
5+
<version>0.0.0</version>
6+
<description>Minimal python package to test python cmake install</description>
7+
8+
<maintainer email="[email protected]">Nadav Elkabets</maintainer>
9+
10+
<license>Apache License 2.0</license>
11+
12+
<buildtool_depend>ament_cmake_core</buildtool_depend>
13+
<build_depend>ament_cmake_python</build_depend>
14+
15+
<buildtool_export_depend>ament_cmake_core</buildtool_export_depend>
16+
17+
<export>
18+
<build_type>ament_cmake</build_type>
19+
</export>
20+
</package>
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
cmake_minimum_required(VERSION 3.12)
2+
3+
project(ament_python_test_package_overlay)
4+
5+
find_package(ament_cmake_core REQUIRED)
6+
7+
find_package(ament_cmake_python REQUIRED)
8+
9+
ament_python_install_package(
10+
ament_python_test_package_overlay
11+
PACKAGE_DIR "${CMAKE_CURRENT_LIST_DIR}/ament_python_test_package"
12+
)
13+
ament_python_install_package(
14+
ament_python_test_package_overlay
15+
PACKAGE_DIR "${CMAKE_CURRENT_LIST_DIR}/ament_python_test_package_overlay"
16+
)
17+
18+
ament_package()

ament_cmake_python_test/test/ament_python_test_package_overlay/ament_python_test_package/__init__.py

Whitespace-only changes.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
class Bar:
2+
def __init__() -> None:
3+
pass

0 commit comments

Comments
 (0)