File: SetUpWorldError.h

package info (click to toggle)
cxxtest 4.4%2Bgit171022-2
  • links: PTS
  • area: main
  • in suites: bookworm, bullseye, sid, trixie
  • size: 2,836 kB
  • sloc: cpp: 9,567; python: 9,553; xml: 435; sh: 258; ruby: 229; makefile: 86; ansic: 68; perl: 16
file content (34 lines) | stat: -rw-r--r-- 625 bytes parent folder | download | duplicates (13)
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
//
// This file tests what happens when setUpWorld() fails
//

#include <cxxtest/TestSuite.h>
#include <cxxtest/GlobalFixture.h>
#include <stdio.h>

class Fixture : public CxxTest::GlobalFixture
{
public:
    bool setUpWorld() { TS_FAIL("THIS IS BAD"); return false; }
};

//
// We can rely on this file being included exactly once
// and declare this global variable in the header file.
//
static Fixture fixture;

class Suite : public CxxTest::TestSuite
{
public:

    void testOne()
    {
        TS_FAIL("Shouldn't get here at all");
    }

    void testTwo()
    {
        TS_FAIL("Shouldn't get here at all");
    }
};