From: Ali Maredia Date: Thu, 28 Jan 2016 21:50:53 +0000 (-0500) Subject: cmake: moved tests into test/pybind dir X-Git-Tag: v10.2.0~27^2~45 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=ef8b113d070c69252b11f84e39f26b25bc9ac42f;p=ceph.git cmake: moved tests into test/pybind dir Added a CMakeLists.txt into test/pybind. Added CEPH_BIN in front of relative path in test_ceph_argparse.py. Signed-off-by: Ali Maredia --- diff --git a/src/test/CMakeLists.txt b/src/test/CMakeLists.txt index f43d02054752..ac2ac6856947 100644 --- a/src/test/CMakeLists.txt +++ b/src/test/CMakeLists.txt @@ -959,10 +959,7 @@ add_ceph_unittest(unittest_lfnindex ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/unittest_l target_link_libraries(unittest_lfnindex os global) add_subdirectory(osd) - -#pybind -add_ceph_test(test_ceph_daemon.py ${CMAKE_SOURCE_DIR}/src/test/pybind/test_ceph_daemon.py) -add_ceph_test(test_ceph_argparse.py ${CMAKE_SOURCE_DIR}/src/test/pybind/test_ceph_argparse.py) +add_subdirectory(pybind) # unittest_admin_socket add_executable(unittest_admin_socket EXCLUDE_FROM_ALL diff --git a/src/test/pybind/CMakeLists.txt b/src/test/pybind/CMakeLists.txt new file mode 100644 index 000000000000..bc91bce305da --- /dev/null +++ b/src/test/pybind/CMakeLists.txt @@ -0,0 +1,2 @@ +add_ceph_test(test_ceph_daemon.py ${CMAKE_CURRENT_SOURCE_DIR}/test_ceph_daemon.py) +add_ceph_test(test_ceph_argparse.py ${CMAKE_CURRENT_SOURCE_DIR}/test_ceph_argparse.py) diff --git a/src/test/pybind/test_ceph_argparse.py b/src/test/pybind/test_ceph_argparse.py index 4bf6c27f9bb7..4c325f278e52 100755 --- a/src/test/pybind/test_ceph_argparse.py +++ b/src/test/pybind/test_ceph_argparse.py @@ -25,7 +25,8 @@ import re import json def get_command_descriptions(what): - return os.popen("./get_command_descriptions " + "--" + what).read() + CEPH_BIN = os.environ['CEPH_BIN'] + return os.popen(CEPH_BIN + "/get_command_descriptions " + "--" + what).read() def test_parse_json_funcsigs(): commands = get_command_descriptions("all")