diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt index fd5aed1fa..0783209c8 100644 --- a/src/tests/CMakeLists.txt +++ b/src/tests/CMakeLists.txt @@ -479,13 +479,13 @@ if(ENABLE_SYSTEM_TESTING) if(GPSTK_FOUND OR OWN_GPSTK) add_executable(obs_gps_l1_system_test ${CMAKE_CURRENT_SOURCE_DIR}/system-tests/obs_gps_l1_system_test.cc) - add_executable(obs_space_system_test ${CMAKE_CURRENT_SOURCE_DIR}/system-tests/obs_space_system_test.cc) + add_executable(obs_system_test ${CMAKE_CURRENT_SOURCE_DIR}/system-tests/obs_system_test.cc) if(NOT ${GTEST_DIR_LOCAL}) add_dependencies(obs_gps_l1_system_test gtest-${GNSSSDR_GTEST_LOCAL_VERSION} ) - add_dependencies(obs_space_system_test gtest-${GNSSSDR_GTEST_LOCAL_VERSION} ) + add_dependencies(obs_system_test gtest-${GNSSSDR_GTEST_LOCAL_VERSION} ) else(NOT ${GTEST_DIR_LOCAL}) add_dependencies(obs_gps_l1_system_test gtest) - add_dependencies(obs_space_system_test gtest) + add_dependencies(obs_system_test gtest) endif(NOT ${GTEST_DIR_LOCAL}) include_directories(${GPSTK_INCLUDE_DIRS} ${GPSTK_INCLUDE_DIRS}/gpstk) target_link_libraries(obs_gps_l1_system_test ${GFlags_LIBS} @@ -495,7 +495,7 @@ if(ENABLE_SYSTEM_TESTING) gnss_rx ${gpstk_libs}) - target_link_libraries(obs_space_system_test ${GFlags_LIBS} + target_link_libraries(obs_system_test ${GFlags_LIBS} ${GLOG_LIBRARIES} ${GTEST_LIBRARIES} gnss_sp_libs @@ -511,9 +511,9 @@ if(ENABLE_SYSTEM_TESTING) add_custom_command(TARGET obs_gps_l1_system_test POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy $ ${CMAKE_SOURCE_DIR}/install/$ ) - add_custom_command(TARGET obs_space_system_test POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy $ - ${CMAKE_SOURCE_DIR}/install/$ ) + add_custom_command(TARGET obs_system_test POST_BUILD + COMMAND ${CMAKE_COMMAND} -E copy $ + ${CMAKE_SOURCE_DIR}/install/$ ) endif(ENABLE_INSTALL_TESTS) endif(GPSTK_FOUND OR OWN_GPSTK) diff --git a/src/tests/system-tests/obs_space_system_test.cc b/src/tests/system-tests/obs_system_test.cc similarity index 97% rename from src/tests/system-tests/obs_space_system_test.cc rename to src/tests/system-tests/obs_system_test.cc index a227733f1..cb82f302c 100644 --- a/src/tests/system-tests/obs_space_system_test.cc +++ b/src/tests/system-tests/obs_system_test.cc @@ -1,5 +1,5 @@ /*! - * \file obs_space_system_test.cc + * \file obs_system_test.cc * \brief This class implements a test for the validation of generated observables. * \author Carles Fernandez-Prades, 2016. cfernandez(at)cttc.es * Antonio Ramos, 2017. antonio.ramos(at)cttc.es @@ -67,7 +67,7 @@ DEFINE_double(cp_error_std_max, 50.0, "Maximum standard deviation in carrier pha DEFINE_double(dp_error_mean_max, 5.0, "Maximum mean error in Doppler frequency"); DEFINE_double(dp_error_std_max, 10.0, "Maximum standard deviation in Doppler frequency"); -class ObsSpaceSystemTest: public ::testing::Test +class ObsSystemTest: public ::testing::Test { public: int configure_receiver(); @@ -118,7 +118,7 @@ public: }; -bool ObsSpaceSystemTest::check_valid_rinex_obs(std::string filename, int rinex_ver) +bool ObsSystemTest::check_valid_rinex_obs(std::string filename, int rinex_ver) { bool res = false; if(rinex_ver == 2) @@ -132,7 +132,7 @@ bool ObsSpaceSystemTest::check_valid_rinex_obs(std::string filename, int rinex_v return res; } -void ObsSpaceSystemTest::read_rinex_files( +void ObsSystemTest::read_rinex_files( std::vector& pseudorange_ref, std::vector& carrierphase_ref, std::vector& doppler_ref, @@ -321,7 +321,7 @@ void ObsSpaceSystemTest::read_rinex_files( EXPECT_TRUE(meas_exist) << "RINEX generated file does not contain " << signal_type_string << " information"; } -void ObsSpaceSystemTest::time_alignment_diff( +void ObsSystemTest::time_alignment_diff( std::vector& ref, std::vector& meas, std::vector& diff) @@ -351,7 +351,7 @@ void ObsSpaceSystemTest::time_alignment_diff( } } -int ObsSpaceSystemTest::configure_receiver() +int ObsSystemTest::configure_receiver() { config = std::make_shared(configuration_file_); int d_rinex_ver = config->property("PVT.rinex_version", 0); @@ -372,7 +372,7 @@ int ObsSpaceSystemTest::configure_receiver() return 0; } -int ObsSpaceSystemTest::run_receiver() +int ObsSystemTest::run_receiver() { std::shared_ptr control_thread; control_thread = std::make_shared(config); @@ -410,7 +410,7 @@ int ObsSpaceSystemTest::run_receiver() return 0; } -void ObsSpaceSystemTest::compute_pseudorange_error( +void ObsSystemTest::compute_pseudorange_error( std::vector& diff, double error_th_mean, double error_th_std) { @@ -432,7 +432,7 @@ void ObsSpaceSystemTest::compute_pseudorange_error( } } -void ObsSpaceSystemTest::compute_carrierphase_error( +void ObsSystemTest::compute_carrierphase_error( std::vector& diff, double error_th_mean, double error_th_std) { @@ -454,7 +454,7 @@ void ObsSpaceSystemTest::compute_carrierphase_error( } } -void ObsSpaceSystemTest::compute_doppler_error( +void ObsSystemTest::compute_doppler_error( std::vector& diff, double error_th_mean, double error_th_std) { @@ -475,7 +475,7 @@ void ObsSpaceSystemTest::compute_doppler_error( prn_id++; } } -void ObsSpaceSystemTest::check_results() +void ObsSystemTest::check_results() { if(gps_1C) { @@ -624,7 +624,7 @@ void ObsSpaceSystemTest::check_results() } -TEST_F(ObsSpaceSystemTest, Observables_system_test) +TEST_F(ObsSystemTest, Observables_system_test) { std::cout << "Validating input RINEX obs (TRUE) file: " << filename_rinex_obs << " ..." << std::endl; bool is_rinex_obs_valid = check_valid_rinex_obs(filename_rinex_obs, 3);