17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
# import "ObjFW.h"
#else
# import <ObjFW/ObjFW.h>
#endif
OF_ASSUME_NONNULL_BEGIN
@interface OTTestCase: OFObject
#ifdef OF_HAVE_CLASS_PROPERTIES
@property (class, readonly, nullable, nonatomic)
OFArray OF_GENERIC(OFPair OF_GENERIC(OFString *, id) *) *summary;
#endif
+ (nullable OFArray OF_GENERIC(OFPair OF_GENERIC(OFString *, id) *) *)summary;
- (void)setUp;
- (void)tearDown;
@end
OF_ASSUME_NONNULL_END
|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
|
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
|
# import "ObjFW.h"
#else
# import <ObjFW/ObjFW.h>
#endif
OF_ASSUME_NONNULL_BEGIN
/**
* @brief A class meant for subclassing to create a test case, consisting of
* one or more tests.
*
* All methods with the prefix `test` that take no arguments of all classes
* that subclass this class are automatically executed by ObjFWTest.
*/
@interface OTTestCase: OFObject
#ifdef OF_HAVE_CLASS_PROPERTIES
@property (class, readonly, nullable, nonatomic)
OFArray OF_GENERIC(OFPair OF_GENERIC(OFString *, id) *) *summary;
#endif
/**
* @brief Returns a summary for the test case that should be printed once all
* tests in all test cases were run.
*
* This is mostly useful to print something at the end of all tests that needs
* manual verification.
*/
+ (nullable OFArray OF_GENERIC(OFPair OF_GENERIC(OFString *, id) *) *)summary;
/**
* @brief Set up method that is run before every test in the test case.
*/
- (void)setUp;
/**
* @brief Tear down method that is run after every test in the test case.
*/
- (void)tearDown;
@end
OF_ASSUME_NONNULL_END
|