* add test_mu_util_get_dtype_with_lstat unit test, cosmetics

This commit is contained in:
Dirk-Jan C. Binnema 2010-12-12 18:33:25 +02:00
parent a315e15081
commit b00a85ec07
1 changed files with 128 additions and 112 deletions

View File

@ -213,6 +213,19 @@ test_mu_util_str_from_strv_03 (void)
}
static void
test_mu_util_get_dtype_with_lstat (void)
{
g_assert_cmpuint (
mu_util_get_dtype_with_lstat (MU_TESTMAILDIR), ==, DT_DIR);
g_assert_cmpuint (
mu_util_get_dtype_with_lstat (MU_TESTMAILDIR2), ==, DT_DIR);
g_assert_cmpuint (
mu_util_get_dtype_with_lstat (MU_TESTMAILDIR2 "Foo/cur/mail4"),
==, DT_REG);
}
int
main (int argc, char *argv[])
@ -245,6 +258,9 @@ main (int argc, char *argv[])
g_test_add_func ("/mu-util/mu-util-str-from-strv-03",
test_mu_util_str_from_strv_03);
g_test_add_func ("/mu-util/mu-util-get-dtype-with-lstat",
test_mu_util_get_dtype_with_lstat);
g_log_set_handler (NULL,
G_LOG_LEVEL_DEBUG|
G_LOG_LEVEL_MESSAGE|