aboutsummaryrefslogtreecommitdiff
path: root/tests/test-string-input-visitor.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test-string-input-visitor.c')
-rw-r--r--tests/test-string-input-visitor.c50
1 files changed, 25 insertions, 25 deletions
diff --git a/tests/test-string-input-visitor.c b/tests/test-string-input-visitor.c
index d406263aee..877e737714 100644
--- a/tests/test-string-input-visitor.c
+++ b/tests/test-string-input-visitor.c
@@ -54,62 +54,62 @@ static void test_visitor_in_int(TestInputVisitorData *data,
const void *unused)
{
int64_t res = 0, value = -42;
- Error *errp = NULL;
+ Error *err = NULL;
Visitor *v;
v = visitor_input_test_init(data, "-42");
- visit_type_int(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_int(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpint(res, ==, value);
}
static void test_visitor_in_bool(TestInputVisitorData *data,
const void *unused)
{
- Error *errp = NULL;
+ Error *err = NULL;
bool res = false;
Visitor *v;
v = visitor_input_test_init(data, "true");
- visit_type_bool(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_bool(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpint(res, ==, true);
visitor_input_teardown(data, unused);
v = visitor_input_test_init(data, "yes");
- visit_type_bool(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_bool(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpint(res, ==, true);
visitor_input_teardown(data, unused);
v = visitor_input_test_init(data, "on");
- visit_type_bool(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_bool(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpint(res, ==, true);
visitor_input_teardown(data, unused);
v = visitor_input_test_init(data, "false");
- visit_type_bool(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_bool(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpint(res, ==, false);
visitor_input_teardown(data, unused);
v = visitor_input_test_init(data, "no");
- visit_type_bool(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_bool(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpint(res, ==, false);
visitor_input_teardown(data, unused);
v = visitor_input_test_init(data, "off");
- visit_type_bool(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_bool(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpint(res, ==, false);
}
@@ -117,13 +117,13 @@ static void test_visitor_in_number(TestInputVisitorData *data,
const void *unused)
{
double res = 0, value = 3.14;
- Error *errp = NULL;
+ Error *err = NULL;
Visitor *v;
v = visitor_input_test_init(data, "3.14");
- visit_type_number(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_number(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpfloat(res, ==, value);
}
@@ -131,13 +131,13 @@ static void test_visitor_in_string(TestInputVisitorData *data,
const void *unused)
{
char *res = NULL, *value = (char *) "Q E M U";
- Error *errp = NULL;
+ Error *err = NULL;
Visitor *v;
v = visitor_input_test_init(data, value);
- visit_type_str(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_str(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpstr(res, ==, value);
g_free(res);
@@ -146,7 +146,7 @@ static void test_visitor_in_string(TestInputVisitorData *data,
static void test_visitor_in_enum(TestInputVisitorData *data,
const void *unused)
{
- Error *errp = NULL;
+ Error *err = NULL;
Visitor *v;
EnumOne i;
@@ -155,8 +155,8 @@ static void test_visitor_in_enum(TestInputVisitorData *data,
v = visitor_input_test_init(data, EnumOne_lookup[i]);
- visit_type_EnumOne(v, &res, NULL, &errp);
- g_assert(!errp);
+ visit_type_EnumOne(v, &res, NULL, &err);
+ g_assert(!err);
g_assert_cmpint(i, ==, res);
visitor_input_teardown(data, NULL);