1 #include <stdarg.h> 2 #include <stddef.h> 3 #include <setjmp.h> 4 #include <cmocka.h> 5 #include <stdlib.h> 6 #include <string.h> 7 #include <glib.h> 8 9 #include "config/preferences.h" 10 11 void statuses_console_defaults_to_all(void ** state)12statuses_console_defaults_to_all(void** state) 13 { 14 char* setting = prefs_get_string(PREF_STATUSES_CONSOLE); 15 16 assert_non_null(setting); 17 assert_string_equal("all", setting); 18 g_free(setting); 19 } 20 21 void statuses_chat_defaults_to_all(void ** state)22statuses_chat_defaults_to_all(void** state) 23 { 24 char* setting = prefs_get_string(PREF_STATUSES_CHAT); 25 26 assert_non_null(setting); 27 assert_string_equal("all", setting); 28 g_free(setting); 29 } 30 31 void statuses_muc_defaults_to_all(void ** state)32statuses_muc_defaults_to_all(void** state) 33 { 34 char* setting = prefs_get_string(PREF_STATUSES_MUC); 35 36 assert_non_null(setting); 37 assert_string_equal("all", setting); 38 g_free(setting); 39 } 40