srsue,test: reorganize test folders and move to components like we in PHY

master
Andre Puschmann 3 years ago
parent 99960c72fa
commit 94959b5318

@ -31,7 +31,6 @@ link_directories(
# Add subdirectories
########################################################################
add_subdirectory(src)
add_subdirectory(test)
########################################################################
# Default configuration files

@ -8,6 +8,7 @@
add_subdirectory(phy)
add_subdirectory(stack)
add_subdirectory(test)
# Link libstdc++ and libgcc
if(BUILD_STATIC)

@ -6,6 +6,8 @@
# the distribution.
#
add_subdirectory(test)
file(GLOB_RECURSE SOURCES "*.cc")
add_library(srsue_phy STATIC ${SOURCES})

@ -6,6 +6,8 @@
# the distribution.
#
add_subdirectory(test)
set(SOURCES demux.cc dl_harq.cc mac.cc mux.cc proc_bsr.cc proc_phr.cc proc_ra.cc proc_sr.cc ul_harq.cc)
add_library(srsue_mac STATIC ${SOURCES})
target_link_libraries(srsue_mac srsue_mac_common ${ATOMIC_LIBS})

@ -6,17 +6,6 @@
# the distribution.
#
add_subdirectory(phy)
add_subdirectory(upper)
if (ENABLE_TTCN3)
add_subdirectory(ttcn3)
endif (ENABLE_TTCN3)
add_executable(metrics_test metrics_test.cc ../src/metrics_stdout.cc ../src/metrics_csv.cc)
target_link_libraries(metrics_test srsran_phy srsran_common)
add_test(metrics_test metrics_test -o ${CMAKE_CURRENT_BINARY_DIR}/ue_metrics.csv)
add_executable(mac_test mac_test.cc)
target_link_libraries(mac_test srsue_mac srsue_phy srsran_common srsran_mac srsran_phy srsran_radio srsran_asn1 rrc_asn1 ${CMAKE_THREAD_LIBS_INIT} ${Boost_LIBRARIES})
add_test(mac_test mac_test)

@ -6,6 +6,8 @@
# the distribution.
#
add_subdirectory(test)
set(SOURCES rrc.cc rrc_procedures.cc rrc_meas.cc rrc_cell.cc phy_controller.cc)
add_library(srsue_rrc STATIC ${SOURCES})

@ -6,15 +6,6 @@
# the distribution.
#
add_executable(usim_test usim_test.cc)
target_link_libraries(usim_test srsue_upper srsran_upper srsran_phy rrc_asn1)
add_test(usim_test usim_test)
if(HAVE_PCSC)
add_executable(pcsc_usim_test pcsc_usim_test.cc)
target_link_libraries(pcsc_usim_test srsue_upper srsran_upper srsran_phy)
endif(HAVE_PCSC)
add_executable(rrc_reconfig_test rrc_reconfig_test.cc)
target_link_libraries(rrc_reconfig_test srsue_upper srsran_upper srsran_phy rrc_asn1)
add_test(rrc_reconfig_test rrc_reconfig_test)
@ -23,18 +14,6 @@ add_executable(rrc_meas_test rrc_meas_test.cc)
target_link_libraries(rrc_meas_test srsue_rrc srsue_upper srsran_upper srsran_phy rrc_asn1 rrc_nr_asn1)
add_test(rrc_meas_test rrc_meas_test)
add_executable(nas_test nas_test.cc)
target_link_libraries(nas_test srsue_upper srsran_upper srsran_phy rrc_asn1)
add_test(nas_test nas_test)
add_executable(gw_test gw_test.cc)
target_link_libraries(gw_test srsue_upper srsran_upper srsran_phy)
add_test(gw_test gw_test)
add_executable(tft_test tft_test.cc)
target_link_libraries(tft_test srsue_upper srsran_upper srsran_phy)
add_test(tft_test tft_test)
add_executable(rrc_phy_ctrl_test rrc_phy_ctrl_test.cc)
target_link_libraries(rrc_phy_ctrl_test srsran_common srsue_rrc ${ATOMIC_LIBS})
add_test(rrc_phy_ctrl_test rrc_phy_ctrl_test)
@ -54,5 +33,4 @@ if (NOT ${BUILD_CMD} STREQUAL "")
add_custom_command(TARGET ip_test POST_BUILD COMMAND ${BUILD_CMD})
else(NOT ${BUILD_CMD} STREQUAL "")
message(STATUS "No post-build command defined")
endif (NOT ${BUILD_CMD} STREQUAL "")
endif (NOT ${BUILD_CMD} STREQUAL "")

@ -6,6 +6,8 @@
# the distribution.
#
add_subdirectory(test)
set(SOURCES nas.cc nas_emm_state.cc nas_idle_procedures.cc gw.cc usim_base.cc usim.cc tft_packet_filter.cc)
if(HAVE_PCSC)

@ -0,0 +1,39 @@
#
# Copyright 2013-2021 Software Radio Systems Limited
#
# By using this file, you agree to the terms and conditions set
# forth in the LICENSE file which can be found at the top level of
# the distribution.
#
add_executable(usim_test usim_test.cc)
target_link_libraries(usim_test srsue_upper srsran_upper srsran_phy rrc_asn1)
add_test(usim_test usim_test)
if(HAVE_PCSC)
add_executable(pcsc_usim_test pcsc_usim_test.cc)
target_link_libraries(pcsc_usim_test srsue_upper srsran_upper srsran_phy)
endif(HAVE_PCSC)
add_executable(nas_test nas_test.cc)
target_link_libraries(nas_test srsue_upper srsran_upper srsran_phy rrc_asn1)
add_test(nas_test nas_test)
add_executable(gw_test gw_test.cc)
target_link_libraries(gw_test srsue_upper srsran_upper srsran_phy)
add_test(gw_test gw_test)
add_executable(tft_test tft_test.cc)
target_link_libraries(tft_test srsue_upper srsran_upper srsran_phy)
add_test(tft_test tft_test)
########################################################################
# Option to run command after build (useful for remote builds)
########################################################################
if (NOT ${BUILD_CMD} STREQUAL "")
message(STATUS "Added custom post-build command: ${BUILD_CMD}")
add_custom_command(TARGET ip_test POST_BUILD COMMAND ${BUILD_CMD})
else(NOT ${BUILD_CMD} STREQUAL "")
message(STATUS "No post-build command defined")
endif (NOT ${BUILD_CMD} STREQUAL "")

@ -0,0 +1,15 @@
#
# Copyright 2013-2021 Software Radio Systems Limited
#
# By using this file, you agree to the terms and conditions set
# forth in the LICENSE file which can be found at the top level of
# the distribution.
#
if (ENABLE_TTCN3)
add_subdirectory(ttcn3)
endif (ENABLE_TTCN3)
add_executable(metrics_test metrics_test.cc ../metrics_stdout.cc ../metrics_csv.cc)
target_link_libraries(metrics_test srsran_phy srsran_common)
add_test(metrics_test metrics_test -o ${CMAKE_CURRENT_BINARY_DIR}/ue_metrics.csv)

@ -29,4 +29,4 @@ set(LINK_LIBRARIES srsue_stack
target_link_libraries(ttcn3_dut ${LINK_LIBRARIES})
include_directories(${PROJECT_SOURCE_DIR}/srsue/test/ttcn3/hdr)
include_directories(${PROJECT_SOURCE_DIR}/srsue/src/test/ttcn3/hdr)

@ -10,7 +10,7 @@
*
*/
#include "srsue/test/ttcn3/hdr/ttcn3_syssim.h"
#include "ttcn3_syssim.h"
#include "dut_utils.h"
#include "srsran/mac/pdu_queue.h"
#include "srsran/srslog/srslog.h"

@ -10,7 +10,7 @@
*
*/
#include "srsue/test/ttcn3/hdr/ttcn3_ue.h"
#include "ttcn3_ue.h"
#include "lte_ttcn3_phy.h"
#include "srsue/hdr/stack/ue_stack_lte.h"
#include <sstream>

@ -6,7 +6,7 @@
# the distribution.
#
include_directories(${PROJECT_SOURCE_DIR}/srsue/test/ttcn3/hdr)
include_directories(${PROJECT_SOURCE_DIR}/srsue/src/test/ttcn3/hdr)
add_executable(rapidjson_test rapidjson_test.cc)
target_link_libraries(rapidjson_test srsran_common)

@ -13,7 +13,6 @@
#include "srsran/common/test_common.h"
#include "ttcn3_helpers.h"
#include <iostream>
#include <srsue/test/ttcn3/hdr/ttcn3_helpers.h>
#include <stdio.h>
#include <vector>
Loading…
Cancel
Save