1 | <?php |
||
30 | class Fixture extends Component |
||
31 | { |
||
32 | /** |
||
33 | * @var array the fixtures that this fixture depends on. This must be a list of the dependent |
||
34 | * fixture class names. |
||
35 | */ |
||
36 | public $depends = []; |
||
37 | |||
38 | |||
39 | /** |
||
40 | * Loads the fixture. |
||
41 | * This method is called before performing every test method. |
||
42 | * You should override this method with concrete implementation about how to set up the fixture. |
||
43 | */ |
||
44 | public function load() |
||
47 | |||
48 | /** |
||
49 | * This method is called BEFORE any fixture data is loaded for the current test. |
||
50 | */ |
||
51 | 12 | public function beforeLoad() |
|
54 | |||
55 | /** |
||
56 | * This method is called AFTER all fixture data have been loaded for the current test. |
||
57 | */ |
||
58 | 12 | public function afterLoad() |
|
61 | |||
62 | /** |
||
63 | * Unloads the fixture. |
||
64 | * This method is called after every test method finishes. |
||
65 | * You may override this method to perform necessary cleanup work for the fixture. |
||
66 | */ |
||
67 | 6 | public function unload() |
|
70 | |||
71 | /** |
||
72 | * This method is called BEFORE any fixture data is unloaded for the current test. |
||
73 | */ |
||
74 | 15 | public function beforeUnload() |
|
77 | |||
78 | /** |
||
79 | * This method is called AFTER all fixture data have been unloaded for the current test. |
||
80 | */ |
||
81 | 15 | public function afterUnload() |
|
84 | } |
||
85 |