ref: 804c8eb157abfed45e3928ce75a0ecbe7d68751c
parent: 88a4d8a479fa079113579ec331cfb3f4d5d79aee
author: Paul Brossier <piem@piem.org>
date: Mon Nov 26 06:48:35 EST 2018
[tests] increase tss coverage
--- a/tests/src/spectral/test-dct.c
+++ b/tests/src/spectral/test-dct.c
@@ -9,10 +9,18 @@
uint_t i, j, n_iters = 10; // number of iterations
// create dct object
aubio_dct_t * dct = new_aubio_dct(win_s);
+ aubio_dct_t * tmp;
+ if (new_aubio_dct(0)) return 1;
+
fvec_t * in = new_fvec (win_s); // input buffer
fvec_t * dctout = new_fvec (win_s); // output buffer
fvec_t * out = new_fvec (win_s); // input buffer
+
+ if ((tmp = new_aubio_dct(1)) == 0) return 1;
+ aubio_dct_do(tmp, dctout, out);
+ aubio_dct_rdo(tmp, dctout, out);
+ del_aubio_dct(tmp);
if (!dct || !in || !dctout) {
return_code = 1;
--- a/tests/src/spectral/test-tss.c
+++ b/tests/src/spectral/test-tss.c
@@ -34,6 +34,10 @@
aubio_pvoc_rdo (pvs, ctrans, trans);
}
+ aubio_tss_set_alpha(tss, 4.);
+ aubio_tss_set_beta(tss, 3.);
+ aubio_tss_set_threshold(tss, 3.);
+
del_aubio_pvoc(pv);
del_aubio_pvoc(pvt);
del_aubio_pvoc(pvs);