blob: 18bbb89e899ccb3c3d7199bffa56026a168f3c79 (
plain)
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
|
/* Copyright (c) 2010 James Grenning and Contributed to Unity Project
* ==========================================
* Unity Project - A Test Framework for C
* Copyright (c) 2007 Mike Karlesky, Mark VanderVoord, Greg Williams
* [Released under MIT License. Please refer to license.txt for details]
* ========================================== */
#include "unity_fixture.h"
static int data = -1;
TEST_GROUP(mygroup);
TEST_SETUP(mygroup)
{
data = 0;
}
TEST_TEAR_DOWN(mygroup)
{
data = -1;
}
TEST(mygroup, test1)
{
TEST_ASSERT_EQUAL_INT(0, data);
}
TEST(mygroup, test2)
{
TEST_ASSERT_EQUAL_INT(0, data);
data = 5;
}
TEST(mygroup, test3)
{
data = 7;
TEST_ASSERT_EQUAL_INT(7, data);
}
|