From cb2132ef93675ce0846258889658e75de2ca1e52 Mon Sep 17 00:00:00 2001 From: Gabor Adam Toth Date: Fri, 29 Apr 2011 23:11:40 +0200 Subject: [PATCH] testMatch: use C2ARG --- test/testMatch.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/test/testMatch.c b/test/testMatch.c index b43f036..cdac58a 100644 --- a/test/testMatch.c +++ b/test/testMatch.c @@ -2,17 +2,17 @@ #include "../include/psyc/lib.h" int main() { - if (psyc_matches("_failure_delivery", 0, "_failure_unsuccessful_delivery_death", 0)) return 1; - if (psyc_matches("_failure_trash", 8, "_failure_unsuccessful_delivery_death", 0)) return 2; - if (psyc_matches("_unsuccessful", 0, "_failure_unsuccessful_delivery_death", 0)) return 3; - unless (psyc_matches("_fail", 0, "_failure_unsuccessful_delivery_death", 0)) return 4; - unless (psyc_matches("_truthahn", 0, "_failure_unsuccessful_delivery_death", 0)) return 5; + if (psyc_matches(PSYC_C2ARG("_failure_delivery"), PSYC_C2ARG("_failure_unsuccessful_delivery_death"))) return 1; + if (psyc_matches(PSYC_C2ARG("_failure"), PSYC_C2ARG("_failure_unsuccessful_delivery_death"))) return 2; + if (psyc_matches(PSYC_C2ARG("_unsuccessful"), PSYC_C2ARG("_failure_unsuccessful_delivery_death"))) return 3; + unless (psyc_matches(PSYC_C2ARG("_fail"), PSYC_C2ARG("_failure_unsuccessful_delivery_death"))) return 4; + unless (psyc_matches(PSYC_C2ARG("_truthahn"), PSYC_C2ARG("_failure_unsuccessful_delivery_death"))) return 5; puts("psyc_matches passed all tests."); - unless (psyc_inherits("_failure_delivery", 0, "_failure_unsuccessful_delivery_death", 0)) return 11; - if (psyc_inherits("_failure_unsuccessful", 0, "_failure_unsuccessful_delivery_death", 0)) return 12; - unless (psyc_inherits("_fail", 0, "_failure_unsuccessful_delivery_death", 0)) return 13; + unless (psyc_inherits(PSYC_C2ARG("_failure_delivery"), PSYC_C2ARG("_failure_unsuccessful_delivery_death"))) return 11; + if (psyc_inherits(PSYC_C2ARG("_failure_unsuccessful"), PSYC_C2ARG("_failure_unsuccessful_delivery_death"))) return 12; + unless (psyc_inherits(PSYC_C2ARG("_fail"), PSYC_C2ARG("_failure_unsuccessful_delivery_death"))) return 13; puts("psyc_inherits passed all tests.");