#include #include #include #include "theme.h" static void test_themeget(void) { ulong r; themeinit(); /* will fall back to theme=default */ r = themeget("test", "foreground", DNotacolor); assert(r == 0x808080ff); r = themeget("test", "background", DNotacolor); assert(r == 0x262626ff); r = themeget("test", "notexist", DNotacolor); assert(r == DNotacolor); themeend(); } void main(int argc, char *argv[]) { char wd[256]; ARGBEGIN{ }ARGEND putenv("home", getwd(wd, sizeof(wd))); test_themeget(); exits(nil); }