From 422189b026f3f43d13695b5bb8b7c6875a8801ff Mon Sep 17 00:00:00 2001 From: Carles Fernandez Date: Sun, 28 Oct 2012 14:11:42 +0000 Subject: [PATCH] code cleaning git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@268 64b25241-fba3-4117-9849-534c7e92360d --- .../direct_resampler_conditioner_cc_test.cc | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/src/tests/gnuradio_block/direct_resampler_conditioner_cc_test.cc b/src/tests/gnuradio_block/direct_resampler_conditioner_cc_test.cc index 8022f9caf..643376a1f 100644 --- a/src/tests/gnuradio_block/direct_resampler_conditioner_cc_test.cc +++ b/src/tests/gnuradio_block/direct_resampler_conditioner_cc_test.cc @@ -39,15 +39,14 @@ #include #include #include - #include "gnss_sdr_valve.h" #include "direct_resampler_conditioner_cc.h" -TEST(Direct_Resampler_Conditioner_Cc_Test, InstantiationAndRunTest) { - - double fs_in = 8000000.0; //FS of the signal in Hz - double fs_out = 4000000.0; //FS of the resampled signal in Hz +TEST(Direct_Resampler_Conditioner_Cc_Test, InstantiationAndRunTest) +{ + double fs_in = 8000000.0; // Input sampling frequency in Hz + double fs_out = 4000000.0; // sampling freuqncy of the resampled signal in Hz struct timeval tv; int nsamples = 1000000; //Number of samples to be computed gr_msg_queue_sptr queue = gr_make_msg_queue(0); @@ -58,16 +57,13 @@ TEST(Direct_Resampler_Conditioner_Cc_Test, InstantiationAndRunTest) { long long int end = 0; EXPECT_NO_THROW({ - direct_resampler_conditioner_cc_sptr resampler = direct_resampler_make_conditioner_cc(fs_in, fs_out); - }) << "Failure in instantiation of direct_resampler_conditioner."; direct_resampler_conditioner_cc_sptr resampler = direct_resampler_make_conditioner_cc(fs_in, fs_out); gr_block_sptr sink = gr_make_null_sink(sizeof(gr_complex)); EXPECT_NO_THROW( { - top_block->connect(source, 0, valve, 0); top_block->connect(valve, 0, resampler, 0); top_block->connect(resampler, 0, sink, 0); @@ -83,5 +79,4 @@ TEST(Direct_Resampler_Conditioner_Cc_Test, InstantiationAndRunTest) { }) << "Failure running direct_resampler_conditioner."; std::cout << "Resampled " << nsamples << " samples in " << (end-begin) << " microseconds" << std::endl; - }