Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Added Integration Tests to Buildkite Pipeline #499

Merged
merged 15 commits into from
Jul 9, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,11 @@ find_program(SCCACHE_FOUND sccache)
if (SCCACHE_FOUND)
message(STATUS "Using sccache")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE sccache)
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK sccache)
else()
find_program(CCACHE_FOUND ccache)
if (CCACHE_FOUND)
message(STATUS "Using ccache")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache)
endif()
endif()

Expand Down
6 changes: 6 additions & 0 deletions libraries/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
project(eosio_libraries)

find_program(CCACHE_FOUND ccache)
if (CCACHE_FOUND)
message(STATUS "Using ccache")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
endif()

list(APPEND CMAKE_MODULE_PATH ${EOSIO_CDT_BIN})
include(EosioCDTMacros)

Expand Down
2 changes: 1 addition & 1 deletion modules/TestsExternalProject.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ if (EOSIO_RUN_INTEGRATION_TESTS)
EosioIntegrationTests
SOURCE_DIR "${CMAKE_SOURCE_DIR}/tests/integration"
BINARY_DIR "${CMAKE_BINARY_DIR}/tests/integration"
CMAKE_ARGS -DCMAKE_BUILD_TYPE=${TEST_BUILD_TYPE} -DCMAKE_FRAMEWORK_PATH=${TEST_FRAMEWORK_PATH} -DCMAKE_MODULE_PATH=${TEST_MODULE_PATH} -DEOSIO_ROOT=${EOSIO_ROOT} -DLLVM_DIR=${LLVM_DIR}
CMAKE_ARGS -DCMAKE_BUILD_TYPE=${TEST_BUILD_TYPE} -DCMAKE_FRAMEWORK_PATH=${TEST_FRAMEWORK_PATH} -DCMAKE_MODULE_PATH=${TEST_MODULE_PATH} -DEOSIO_ROOT=${EOSIO_ROOT} -DLLVM_DIR=${LLVM_DIR} -DBOOST_ROOT=${BOOST_ROOT}
UPDATE_COMMAND ""
PATCH_COMMAND ""
TEST_COMMAND ""
Expand Down
10 changes: 10 additions & 0 deletions pipeline.jsonc
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"eosio-dot-cdt":
{
"pipeline-branch": "master",
"dependencies": // dependencies to pull for cdt integration tests, by branch, tag, or commit hash
{
"eosio": "release/1.7.x"
}
}
}
28 changes: 27 additions & 1 deletion tests/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,17 +1,43 @@
find_program(SCCACHE_FOUND sccache)
if (SCCACHE_FOUND)
message(STATUS "Using sccache")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE sccache)
else()
find_program(CCACHE_FOUND ccache)
if (CCACHE_FOUND)
message(STATUS "Using ccache")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
endif()
endif()

add_test( asset_tests ${CMAKE_BINARY_DIR}/tests/unit/asset_tests )
set_property(TEST asset_tests PROPERTY LABELS unit_tests)
add_test( binary_extension_tests ${CMAKE_BINARY_DIR}/tests/unit/binary_extension_tests )
set_property(TEST binary_extension_tests PROPERTY LABELS unit_tests)
add_test( crypto_tests ${CMAKE_BINARY_DIR}/tests/unit/crypto_tests )
set_property(TEST crypto_tests PROPERTY LABELS unit_tests)
add_test( datastream_tests ${CMAKE_BINARY_DIR}/tests/unit/datastream_tests )
set_property(TEST datastream_tests PROPERTY LABELS unit_tests)
add_test( fixed_bytes_tests ${CMAKE_BINARY_DIR}/tests/unit/fixed_bytes_tests )
set_property(TEST fixed_bytes_tests PROPERTY LABELS unit_tests)
add_test( name_tests ${CMAKE_BINARY_DIR}/tests/unit/name_tests )
set_property(TEST name_tests PROPERTY LABELS unit_tests)
add_test( rope_tests ${CMAKE_BINARY_DIR}/tests/unit/rope_tests )
set_property(TEST rope_tests PROPERTY LABELS unit_tests)
add_test( print_tests ${CMAKE_BINARY_DIR}/tests/unit/print_tests )
set_property(TEST print_tests PROPERTY LABELS unit_tests)
add_test( serialize_tests ${CMAKE_BINARY_DIR}/tests/unit/serialize_tests )
set_property(TEST serialize_tests PROPERTY LABELS unit_tests)
add_test( symbol_tests ${CMAKE_BINARY_DIR}/tests/unit/symbol_tests )
set_property(TEST symbol_tests PROPERTY LABELS unit_tests)
add_test( system_tests ${CMAKE_BINARY_DIR}/tests/unit/system_tests )
set_property(TEST system_tests PROPERTY LABELS unit_tests)
add_test( time_tests ${CMAKE_BINARY_DIR}/tests/unit/time_tests )
set_property(TEST time_tests PROPERTY LABELS unit_tests)
add_test( varint_tests ${CMAKE_BINARY_DIR}/tests/unit/varint_tests )
set_property(TEST varint_tests PROPERTY LABELS unit_tests)

if (eosio_FOUND AND EOSIO_RUN_INTEGRATION_TESTS)
add_test(integration_tests ${CMAKE_BINARY_DIR}/tests/integration/integration_tests)
endif()
set_property(TEST integration_tests PROPERTY LABELS integration_tests)
endif()
15 changes: 10 additions & 5 deletions tools/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,16 @@ find_package(LLVM REQUIRED CONFIG)
message(STATUS "Found LLVM ${LLVM_PACKAGE_VERSION}")
message(STATUS "Using LLVMConfig.cmake in: ${LLVM_DIR}")

find_program(CCACHE_FOUND ccache)
if (CCACHE_FOUND)
message(STATUS "Using ccache")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache)
find_program(SCCACHE_FOUND sccache)
if (SCCACHE_FOUND)
message(STATUS "Using sccache")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE sccache)
else()
find_program(CCACHE_FOUND ccache)
if (CCACHE_FOUND)
message(STATUS "Using ccache")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
endif()
endif()

include_directories(${LLVM_INCLUDE_DIRS})
Expand Down