diff options
Diffstat (limited to 'gnuradio-core/src/tests')
-rw-r--r-- | gnuradio-core/src/tests/.gitignore | 28 | ||||
-rw-r--r-- | gnuradio-core/src/tests/CMakeLists.txt | 8 | ||||
-rw-r--r-- | gnuradio-core/src/tests/Makefile.am | 105 | ||||
-rwxr-xr-x | gnuradio-core/src/tests/benchmark_dotprod | 8 | ||||
-rw-r--r-- | gnuradio-core/src/tests/benchmark_dotprod_fcc.cc | 2 | ||||
-rw-r--r-- | gnuradio-core/src/tests/benchmark_dotprod_scc.cc | 4 | ||||
-rw-r--r-- | gnuradio-core/src/tests/benchmark_nco.cc | 6 | ||||
-rw-r--r-- | gnuradio-core/src/tests/test_all.cc | 12 | ||||
-rw-r--r-- | gnuradio-core/src/tests/test_atsc.cc | 10 | ||||
-rwxr-xr-x | gnuradio-core/src/tests/test_buffers.py | 10 | ||||
-rw-r--r-- | gnuradio-core/src/tests/test_filter.cc | 12 | ||||
-rw-r--r-- | gnuradio-core/src/tests/test_general.cc | 12 | ||||
-rw-r--r-- | gnuradio-core/src/tests/test_runtime.cc | 12 | ||||
-rw-r--r-- | gnuradio-core/src/tests/test_vmcircbuf.cc | 10 |
14 files changed, 53 insertions, 186 deletions
diff --git a/gnuradio-core/src/tests/.gitignore b/gnuradio-core/src/tests/.gitignore deleted file mode 100644 index 8687003d4..000000000 --- a/gnuradio-core/src/tests/.gitignore +++ /dev/null @@ -1,28 +0,0 @@ -/Makefile -/Makefile.in -/.la -/.lo -/.deps -/.libs -/*.la -/*.lo -/t1 -/test_dtv -/check_dups -/test_gr -/test_all -/exercise_correlator -/test_grbase -/test_vmcircbuf -/test_atsc -/test_general -/test_runtime -/test_filter -/benchmark_dotprod_fff -/benchmark_dotprod_ccc -/benchmark_dotprod_fcc -/benchmark_dotprod_scc -/benchmark_nco -/benchmark_dotprod_ccf -/benchmark_dotprod_fsf -/benchmark_vco diff --git a/gnuradio-core/src/tests/CMakeLists.txt b/gnuradio-core/src/tests/CMakeLists.txt index 34ad36568..3c7f632b3 100644 --- a/gnuradio-core/src/tests/CMakeLists.txt +++ b/gnuradio-core/src/tests/CMakeLists.txt @@ -1,17 +1,17 @@ # Copyright 2010-2012 Free Software Foundation, Inc. -# +# # This file is part of GNU Radio -# +# # GNU Radio is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3, or (at your option) # any later version. -# +# # GNU Radio is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -# +# # You should have received a copy of the GNU General Public License # along with GNU Radio; see the file COPYING. If not, write to # the Free Software Foundation, Inc., 51 Franklin Street, diff --git a/gnuradio-core/src/tests/Makefile.am b/gnuradio-core/src/tests/Makefile.am deleted file mode 100644 index 5879a13d8..000000000 --- a/gnuradio-core/src/tests/Makefile.am +++ /dev/null @@ -1,105 +0,0 @@ -# -# Copyright 2001,2008,2010 Free Software Foundation, Inc. -# -# This file is part of GNU Radio -# -# GNU Radio is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3, or (at your option) -# any later version. -# -# GNU Radio is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Radio; see the file COPYING. If not, write to -# the Free Software Foundation, Inc., 51 Franklin Street, -# Boston, MA 02110-1301, USA. -# - -include $(top_srcdir)/Makefile.common - -AM_CPPFLAGS = $(STD_DEFINES_AND_INCLUDES) $(CPPUNIT_INCLUDES) $(WITH_INCLUDES) - -# list of programs run by "make check" and "make distcheck" - -TESTS = test_all - - -# test_atsc - -#Test program to test setting up buffers using gr_test which can be run manually -EXTRA_DIST += \ - test_buffers.py \ - benchmark_dotprod - - -noinst_PROGRAMS = \ - benchmark_dotprod_fff \ - benchmark_dotprod_fsf \ - benchmark_dotprod_fcc \ - benchmark_dotprod_scc \ - benchmark_dotprod_ccc \ - benchmark_dotprod_ccf \ - benchmark_nco \ - benchmark_vco \ - test_all \ - test_runtime \ - test_general \ - test_filter \ - test_vmcircbuf - -#bin_PROGRAMS = \ -# test_all - - -noinst_SCRIPTS = \ - benchmark_dotprod - - -LIBGNURADIO = $(GNURADIO_CORE_LA) $(BOOST_FILESYSTEM_LIB) -LIBGNURADIOQA = $(top_builddir)/gnuradio-core/src/lib/libgnuradio-core-qa.la $(LIBGNURADIO) - -benchmark_dotprod_fff_SOURCES = benchmark_dotprod_fff.cc -benchmark_dotprod_fff_LDADD = $(LIBGNURADIO) - -benchmark_dotprod_fsf_SOURCES = benchmark_dotprod_fsf.cc -benchmark_dotprod_fsf_LDADD = $(LIBGNURADIO) - -benchmark_dotprod_ccf_SOURCES = benchmark_dotprod_ccf.cc -benchmark_dotprod_ccf_LDADD = $(LIBGNURADIO) - -benchmark_dotprod_fcc_SOURCES = benchmark_dotprod_fcc.cc -benchmark_dotprod_fcc_LDADD = $(LIBGNURADIO) - -benchmark_dotprod_scc_SOURCES = benchmark_dotprod_scc.cc -benchmark_dotprod_scc_LDADD = $(LIBGNURADIO) - -benchmark_dotprod_ccc_SOURCES = benchmark_dotprod_ccc.cc -benchmark_dotprod_ccc_LDADD = $(LIBGNURADIO) - -benchmark_nco_SOURCES = benchmark_nco.cc -benchmark_nco_LDADD = $(LIBGNURADIO) - -benchmark_vco_SOURCES = benchmark_vco.cc -benchmark_vco_LDADD = $(LIBGNURADIO) - -test_runtime_SOURCES = test_runtime.cc -test_runtime_LDADD = $(LIBGNURADIOQA) - -test_general_SOURCES = test_general.cc -test_general_LDADD = $(LIBGNURADIOQA) - -test_filter_SOURCES = test_filter.cc -test_filter_LDADD = $(LIBGNURADIOQA) - -# test_atsc_SOURCES = test_atsc.cc -#test_atsc_LDADD = $(LIBGNURADIOQA) - -test_vmcircbuf_SOURCES = test_vmcircbuf.cc -test_vmcircbuf_LDADD = $(LIBGNURADIOQA) - -test_all_SOURCES = test_all.cc -test_all_LDADD = $(LIBGNURADIOQA) diff --git a/gnuradio-core/src/tests/benchmark_dotprod b/gnuradio-core/src/tests/benchmark_dotprod index 69489e465..82f3b5c3f 100755 --- a/gnuradio-core/src/tests/benchmark_dotprod +++ b/gnuradio-core/src/tests/benchmark_dotprod @@ -1,19 +1,19 @@ #!/bin/sh # # Copyright 2008 Free Software Foundation, Inc. -# +# # This file is part of GNU Radio -# +# # GNU Radio is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3, or (at your option) # any later version. -# +# # GNU Radio is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -# +# # You should have received a copy of the GNU General Public License along # with this program; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. diff --git a/gnuradio-core/src/tests/benchmark_dotprod_fcc.cc b/gnuradio-core/src/tests/benchmark_dotprod_fcc.cc index 8363a03b3..e9eeee43a 100644 --- a/gnuradio-core/src/tests/benchmark_dotprod_fcc.cc +++ b/gnuradio-core/src/tests/benchmark_dotprod_fcc.cc @@ -79,7 +79,7 @@ benchmark (fir_maker_t filter_maker, const char *implementation_name) std::vector<gr_complex> taps (&coeffs[0], &coeffs[NTAPS]); filter_t *f = filter_maker (taps); - + // get starting CPU usage #ifdef HAVE_SYS_RESOURCE_H if (getrusage (RUSAGE_SELF, &rusage_start) < 0){ diff --git a/gnuradio-core/src/tests/benchmark_dotprod_scc.cc b/gnuradio-core/src/tests/benchmark_dotprod_scc.cc index 49bbfe5bf..9a65bb4c6 100644 --- a/gnuradio-core/src/tests/benchmark_dotprod_scc.cc +++ b/gnuradio-core/src/tests/benchmark_dotprod_scc.cc @@ -66,7 +66,7 @@ benchmark (fir_maker_t filter_maker, const char *implementation_name) double clock_start; double clock_end; #endif - + // setup coefficients and input data @@ -78,7 +78,7 @@ benchmark (fir_maker_t filter_maker, const char *implementation_name) std::vector<gr_complex> taps (&coeffs[0], &coeffs[NTAPS]); filter_t *f = filter_maker (taps); - + // get starting CPU usage #ifdef HAVE_SYS_RESOURCE_H diff --git a/gnuradio-core/src/tests/benchmark_nco.cc b/gnuradio-core/src/tests/benchmark_nco.cc index 9c4eff346..20d53e410 100644 --- a/gnuradio-core/src/tests/benchmark_nco.cc +++ b/gnuradio-core/src/tests/benchmark_nco.cc @@ -124,7 +124,7 @@ void native_sincos_vec (float *x, float *y) gr_nco<float,float> nco; nco.set_freq (2 * M_PI / FREQ); - + for (int i = 0; i < ITERATIONS/BLOCK_SIZE; i++){ nco.sincos ((gr_complex*)x, BLOCK_SIZE); } @@ -133,9 +133,9 @@ void native_sincos_vec (float *x, float *y) void fxpt_sincos_vec (float *x, float *y) { gr_fxpt_nco nco; - + nco.set_freq (2 * M_PI / FREQ); - + for (int i = 0; i < ITERATIONS/BLOCK_SIZE; i++){ nco.sincos ((gr_complex*)x, BLOCK_SIZE); } diff --git a/gnuradio-core/src/tests/test_all.cc b/gnuradio-core/src/tests/test_all.cc index 6cec8ad0e..8a1423e9e 100644 --- a/gnuradio-core/src/tests/test_all.cc +++ b/gnuradio-core/src/tests/test_all.cc @@ -1,19 +1,19 @@ /* -*- c++ -*- */ /* * Copyright 2002,2010,2011 Free Software Foundation, Inc. - * + * * This file is part of GNU Radio - * + * * GNU Radio is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3, or (at your option) * any later version. - * + * * GNU Radio is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with GNU Radio; see the file COPYING. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, @@ -31,7 +31,7 @@ // FIXME add atsc back in. -int +int main (int argc, char **argv) { CppUnit::TextTestRunner runner; @@ -43,7 +43,7 @@ main (int argc, char **argv) runner.addTest (qa_filter::suite ()); // runner.addTest (qa_atsc::suite ()); runner.setOutputter(xmlout); - + bool was_successful = runner.run ("", false); return was_successful ? 0 : 1; diff --git a/gnuradio-core/src/tests/test_atsc.cc b/gnuradio-core/src/tests/test_atsc.cc index 66cb2a312..d99bccce5 100644 --- a/gnuradio-core/src/tests/test_atsc.cc +++ b/gnuradio-core/src/tests/test_atsc.cc @@ -1,19 +1,19 @@ /* -*- c++ -*- */ /* * Copyright 2002,2011 Free Software Foundation, Inc. - * + * * This file is part of GNU Radio - * + * * GNU Radio is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3, or (at your option) * any later version. - * + * * GNU Radio is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with GNU Radio; see the file COPYING. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, @@ -26,7 +26,7 @@ #include <gr_unittests.h> #include <qa_atsc.h> -int +int main (int argc, char **argv) { CppUnit::TextTestRunner runner; diff --git a/gnuradio-core/src/tests/test_buffers.py b/gnuradio-core/src/tests/test_buffers.py index 186a60bb9..b867c727c 100755 --- a/gnuradio-core/src/tests/test_buffers.py +++ b/gnuradio-core/src/tests/test_buffers.py @@ -1,24 +1,24 @@ #!/usr/bin/env python # # Copyright 2006 Free Software Foundation, Inc. -# +# # This file is part of GNU Radio -# +# # GNU Radio is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3, or (at your option) # any later version. -# +# # GNU Radio is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -# +# # You should have received a copy of the GNU General Public License # along with GNU Radio; see the file COPYING. If not, write to # the Free Software Foundation, Inc., 51 Franklin Street, # Boston, MA 02110-1301, USA. -# +# from gnuradio import gr, gru from gnuradio import audio diff --git a/gnuradio-core/src/tests/test_filter.cc b/gnuradio-core/src/tests/test_filter.cc index 3227a9ff2..8b17034c6 100644 --- a/gnuradio-core/src/tests/test_filter.cc +++ b/gnuradio-core/src/tests/test_filter.cc @@ -1,19 +1,19 @@ /* -*- c++ -*- */ /* * Copyright 2002,2010,2011 Free Software Foundation, Inc. - * + * * This file is part of GNU Radio - * + * * GNU Radio is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3, or (at your option) * any later version. - * + * * GNU Radio is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with GNU Radio; see the file COPYING. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, @@ -26,7 +26,7 @@ #include <gr_unittests.h> #include <qa_filter.h> -int +int main (int argc, char **argv) { CppUnit::TextTestRunner runner; @@ -35,7 +35,7 @@ main (int argc, char **argv) runner.addTest (qa_filter::suite ()); runner.setOutputter(xmlout); - + bool was_successful = runner.run ("", false); return was_successful ? 0 : 1; diff --git a/gnuradio-core/src/tests/test_general.cc b/gnuradio-core/src/tests/test_general.cc index ca6dee40a..32fac1b35 100644 --- a/gnuradio-core/src/tests/test_general.cc +++ b/gnuradio-core/src/tests/test_general.cc @@ -1,19 +1,19 @@ /* -*- c++ -*- */ /* * Copyright 2002,2010,2011 Free Software Foundation, Inc. - * + * * This file is part of GNU Radio - * + * * GNU Radio is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3, or (at your option) * any later version. - * + * * GNU Radio is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with GNU Radio; see the file COPYING. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, @@ -26,7 +26,7 @@ #include <gr_unittests.h> #include <qa_general.h> -int +int main (int argc, char **argv) { CppUnit::TextTestRunner runner; @@ -35,7 +35,7 @@ main (int argc, char **argv) runner.addTest (qa_general::suite ()); runner.setOutputter(xmlout); - + bool was_successful = runner.run ("", false); return was_successful ? 0 : 1; diff --git a/gnuradio-core/src/tests/test_runtime.cc b/gnuradio-core/src/tests/test_runtime.cc index 77af3001b..bd5378332 100644 --- a/gnuradio-core/src/tests/test_runtime.cc +++ b/gnuradio-core/src/tests/test_runtime.cc @@ -1,19 +1,19 @@ /* -*- c++ -*- */ /* * Copyright 2002,2010,2011 Free Software Foundation, Inc. - * + * * This file is part of GNU Radio - * + * * GNU Radio is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3, or (at your option) * any later version. - * + * * GNU Radio is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with GNU Radio; see the file COPYING. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, @@ -26,7 +26,7 @@ #include <gr_unittests.h> #include <qa_runtime.h> -int +int main (int argc, char **argv) { CppUnit::TextTestRunner runner; @@ -35,7 +35,7 @@ main (int argc, char **argv) runner.addTest (qa_runtime::suite ()); runner.setOutputter(xmlout); - + bool was_successful = runner.run ("", false); return was_successful ? 0 : 1; diff --git a/gnuradio-core/src/tests/test_vmcircbuf.cc b/gnuradio-core/src/tests/test_vmcircbuf.cc index 5145b17c4..ee24b6d62 100644 --- a/gnuradio-core/src/tests/test_vmcircbuf.cc +++ b/gnuradio-core/src/tests/test_vmcircbuf.cc @@ -1,19 +1,19 @@ /* -*- c++ -*- */ /* * Copyright 2003 Free Software Foundation, Inc. - * + * * This file is part of GNU Radio - * + * * GNU Radio is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3, or (at your option) * any later version. - * + * * GNU Radio is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with GNU Radio; see the file COPYING. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, @@ -23,7 +23,7 @@ #include <gr_vmcircbuf.h> #include <stdio.h> -int +int main (int argc, char **argv) { int verbose = 1; // summary |