File tree Expand file tree Collapse file tree 3 files changed +48
-5
lines changed Expand file tree Collapse file tree 3 files changed +48
-5
lines changed Original file line number Diff line number Diff line change 2828 cmake -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_FLAGS="-Werror" ..
2929 make
3030 /home/runner/work/github_actions_gtest_example/github_actions_gtest_example/build/test/github_actions_gtest_example.test
31+
32+ build-macos :
33+ runs-on : macos-latest
34+ steps :
35+ - name : Download, configure and install gtest
36+ run : |
37+ wget https://github.com/google/googletest/archive/release-1.10.0.tar.gz
38+ tar xf release-1.10.0.tar.gz
39+ cd googletest-release-1.10.0
40+ cmake -DBUILD_SHARED_LIBS=OFF .
41+ sudo make install
42+ - name : Checkout the project
43+ uses : actions/checkout@v1
44+ - name : Do some tests
45+ run : |
46+ mkdir build
47+ cd build
48+ cmake -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_FLAGS="-Werror" ..
49+ VERBOSE=1 make
50+ /home/runner/work/github_actions_gtest_example/github_actions_gtest_example/build/test/github_actions_gtest_example.test
Original file line number Diff line number Diff line change 1414 steps :
1515 - name : Download, configure and install gtest
1616 run : |
17- wget https://github.com/google/googletest/archive/release-1.10 .0.tar.gz
18- tar xf release-1.10 .0.tar.gz
19- cd googletest-release-1.10 .0
17+ wget https://github.com/google/googletest/archive/release-1.11 .0.tar.gz
18+ tar xf release-1.11 .0.tar.gz
19+ cd googletest-release-1.11 .0
2020 cmake -DBUILD_SHARED_LIBS=OFF .
2121 sudo make install
2222 - name : Checkout the project
2828 cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_FLAGS="-Werror" ..
2929 make
3030 /home/runner/work/github_actions_gtest_example/github_actions_gtest_example/build/test/github_actions_gtest_example.test
31+
32+ build-macos :
33+ runs-on : macos-latest
34+ steps :
35+ - name : Download, configure and install gtest
36+ run : |
37+ wget https://github.com/google/googletest/archive/release-1.11.0.tar.gz
38+ tar xf release-1.11.0.tar.gz
39+ cd googletest-release-1.11.0
40+ cmake -DBUILD_SHARED_LIBS=OFF .
41+ sudo make install
42+ - name : Checkout the project
43+ uses : actions/checkout@v1
44+ - name : Do some tests
45+ run : |
46+ mkdir build
47+ cd build
48+ cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_FLAGS="-Werror" ..
49+ VERBOSE=1 make
50+ /home/runner/work/github_actions_gtest_example/github_actions_gtest_example/build/test/github_actions_gtest_example.test
Original file line number Diff line number Diff line change @@ -2,9 +2,12 @@ add_executable(${PROJECT_NAME}.test
22 AllTests.cpp
33 ${PROJECT_NAME} Test .cpp)
44target_link_libraries (${PROJECT_NAME} .test
5- ${PROJECT_NAME} gtest pthread)
5+ ${PROJECT_NAME} gtest gmock pthread)
66target_compile_definitions (${PROJECT_NAME} .test
77 PRIVATE TEST_DIR="${CMAKE_CURRENT_LIST_DIR} /test" )
8-
98install (TARGETS ${PROJECT_NAME} .test
109 DESTINATION "${tool_dest} " )
10+
11+ # Mac OS X does not look at these paths
12+ target_include_directories (${PROJECT_NAME} .test PRIVATE "/usr/local/include/" )
13+ set (CMAKE_LIBRARY_PATH "/usr/local/lib/" )
You can’t perform that action at this time.
0 commit comments