tests: Relax a refcount comparison check

We now test for real_refcount >= expected_refcount, because various
parts of the code (a11y, selection, cursor, ...) can and do add
references.
This commit is contained in:
Benjamin Otte 2011-12-16 13:38:06 +01:00
parent 113aff673f
commit e104219ab1

View File

@ -239,7 +239,12 @@ check_iter (GtkTreeModelRefCount *ref_model,
}
if (may_assert)
g_assert_cmpint (expected_ref_count, ==, info->ref_count);
{
if (expected_ref_count == 0)
g_assert_cmpint (expected_ref_count, ==, info->ref_count);
else
g_assert_cmpint (expected_ref_count, <=, info->ref_count);
}
return expected_ref_count == info->ref_count;
}