blob: d725278a009d52118a41074f3b98fa665e98811f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
// Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
/**
* Implementation of the test suite application SrcTestSuite.
*
* @file SrcTestSuite.cpp
*
* @author Knut Omang
*
* @date Created 21 Feb 2003
*
* $Id$
*
* <pre>
* Copyright (c) : 2003 Fast Search & Transfer ASA
* ALL RIGHTS RESERVED
* </pre>
****************************************************************************/
#include <vespa/fastos/fastos.h>
#include <vespa/log/log.h>
LOG_SETUP("SrcTestSuite");
#include <vespa/fastlib/testsuite/suite.h>
#include "testenv.h"
#include "mcandTest.h"
#include "queryparserTest.h"
#include "matchobjectTest.h"
#include "auxTest.h"
/**
* The SrcTestSuite class runs all the unit tests for the src module.
*
* @author Knut Omang
*/
class SrcTestSuite : public Suite {
public:
SrcTestSuite();
};
SrcTestSuite::SrcTestSuite() :
Suite("SrcTestSuite", &std::cout)
{
// All tests for this module
AddTest(new MatchCandidateTest());
AddTest(new MatchObjectTest());
AddTest(new QueryParserTest());
AddTest(new AuxTest());
}
/**
* The SrcTestSuiteApp class holds the main body for running the
* SrcTestSuite class.
*
* @author Knut Omang
*/
class SrcTestSuiteApp : public FastOS_Application {
public:
virtual int Main();
};
int SrcTestSuiteApp::Main() {
juniper::TestEnv te(this, "../rpclient/testclient.rc");
SrcTestSuite suite;
suite.Run();
long failures = suite.Report();
suite.Free();
return (int)failures;
}
FASTOS_MAIN(SrcTestSuiteApp);
|