Skip to content

Commit

Permalink
fix(test): ctest unable to find executable
Browse files Browse the repository at this point in the history
  • Loading branch information
lotem committed Feb 10, 2024
1 parent 24fa8ae commit 0061e24
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
4 changes: 1 addition & 3 deletions build.bat
Expand Up @@ -200,10 +200,8 @@ cmake --build %build_dir% --config %build_config% --target install
if errorlevel 1 goto error

if "%build_test%" == "ON" (
pushd %build_dir%
ctest --output-on-failure
ctest --test-dir %build_dir% -C %build_config% --output-on-failure
if errorlevel 1 goto error
popd
)

echo.
Expand Down
5 changes: 3 additions & 2 deletions test/CMakeLists.txt
Expand Up @@ -13,5 +13,6 @@ endif(BUILD_SHARED_LIBS)
file(GLOB test_data_files ${PROJECT_SOURCE_DIR}/data/test/*.yaml)
file(COPY ${test_data_files} DESTINATION ${EXECUTABLE_OUTPUT_PATH})

set(rime_test_executable ${EXECUTABLE_OUTPUT_PATH}/rime_test${ext})
add_test(rime_test ${rime_test_executable})
add_test(NAME rime_test
COMMAND rime_test
WORKING_DIRECTORY ${EXECUTABLE_OUTPUT_PATH})

0 comments on commit 0061e24

Please sign in to comment.