comparison data/model/test/svcore-data-model-test.cpp @ 1609:560453546749 single-point

Start some sparse model tests
author Chris Cannam
date Tue, 05 Mar 2019 13:21:55 +0000
parents a090221caeda
children
comparison
equal deleted inserted replaced
1608:0e0947896fd3 1609:560453546749
12 */ 12 */
13 13
14 #include "TestFFTModel.h" 14 #include "TestFFTModel.h"
15 #include "TestZoomConstraints.h" 15 #include "TestZoomConstraints.h"
16 #include "TestWaveformOversampler.h" 16 #include "TestWaveformOversampler.h"
17 #include "TestSparseModels.h"
17 18
18 #include "system/Init.h" 19 #include "system/Init.h"
19 20
20 #include <QtTest> 21 #include <QtTest>
21 22
29 30
30 svSystemSpecificInitialisation(); 31 svSystemSpecificInitialisation();
31 32
32 QCoreApplication app(argc, argv); 33 QCoreApplication app(argc, argv);
33 app.setOrganizationName("sonic-visualiser"); 34 app.setOrganizationName("sonic-visualiser");
34 app.setApplicationName("test-model"); 35 app.setApplicationName("test-svcore-data-model");
35 36
36 { 37 {
37 TestFFTModel t; 38 TestFFTModel t;
38 if (QTest::qExec(&t, argc, argv) == 0) ++good; 39 if (QTest::qExec(&t, argc, argv) == 0) ++good;
39 else ++bad; 40 else ++bad;
49 TestWaveformOversampler t; 50 TestWaveformOversampler t;
50 if (QTest::qExec(&t, argc, argv) == 0) ++good; 51 if (QTest::qExec(&t, argc, argv) == 0) ++good;
51 else ++bad; 52 else ++bad;
52 } 53 }
53 54
55 {
56 TestSparseModels t;
57 if (QTest::qExec(&t, argc, argv) == 0) ++good;
58 else ++bad;
59 }
60
54 if (bad > 0) { 61 if (bad > 0) {
55 SVCERR << "\n********* " << bad << " test suite(s) failed!\n" << endl; 62 SVCERR << "\n********* " << bad << " test suite(s) failed!\n" << endl;
56 return 1; 63 return 1;
57 } else { 64 } else {
58 SVCERR << "All tests passed" << endl; 65 SVCERR << "All tests passed" << endl;