check_rules unit test fix

This commit is contained in:
SJ 2015-12-29 15:16:31 +01:00
parent d261cc98de
commit f17e50d3a7

View File

@ -134,10 +134,12 @@ static void test_archiving_rule(struct __config *cfg){
//printf("%s, '%s'\n", rule_test[i].filename, rule); //printf("%s, '%s'\n", rule_test[i].filename, rule);
if(rule == NULL && rule == rule_test[i].expected_result) continue; if(rule){
assert(strcmp(rule, rule_test[i].expected_result) == 0 && "test_archiving_rule()");
assert(strcmp(rule, rule_test[i].expected_result) == 0 && "test_archiving_rule()"); }
else {
assert(rule_test[i].expected_result == NULL && "test_archiving_rule()");
}
} }
clearrules(data.archiving_rules); clearrules(data.archiving_rules);