[maemo-commits] [maemo-commits] r15410 - in projects/haf/trunk/maemo-launcher: . launcher
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Wed Apr 16 01:35:25 EEST 2008
- Previous message: [maemo-commits] r15409 - in projects/haf/trunk/hildon-1: . src
- Next message: [maemo-commits] r15411 - in projects/haf/trunk/maemo-launcher: . launcher
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: guillem Date: 2008-04-16 01:35:24 +0300 (Wed, 16 Apr 2008) New Revision: 15410 Modified: projects/haf/trunk/maemo-launcher/ChangeLog projects/haf/trunk/maemo-launcher/launcher/test_lib.c projects/haf/trunk/maemo-launcher/launcher/test_lib.h Log: Add new test_success and test_failure functions Modified: projects/haf/trunk/maemo-launcher/ChangeLog =================================================================== --- projects/haf/trunk/maemo-launcher/ChangeLog 2008-04-15 16:06:44 UTC (rev 15409) +++ projects/haf/trunk/maemo-launcher/ChangeLog 2008-04-15 22:35:24 UTC (rev 15410) @@ -1,3 +1,10 @@ +2008-02-21 Guillem Jover <guillem.jover at nokia.com> + + * launcher/test_lib.h (test_success): New function declaration. + (test_failure): Likewise. + * launcher/test_lib.c (test_success): New function. + (test_failure): Likewise. + 2008-01-25 Guillem Jover <guillem.jover at nokia.com> * launcher/comm_msg.h (comm_msg_reset): New function declaration. Modified: projects/haf/trunk/maemo-launcher/launcher/test_lib.c =================================================================== --- projects/haf/trunk/maemo-launcher/launcher/test_lib.c 2008-04-15 16:06:44 UTC (rev 15409) +++ projects/haf/trunk/maemo-launcher/launcher/test_lib.c 2008-04-15 22:35:24 UTC (rev 15410) @@ -47,6 +47,24 @@ } void +test_success(bool r) +{ + if (r) + ++tests_ok; + else + error("got %d expected %d\n", r, true); +} + +void +test_failure(bool r) +{ + if (!r) + ++tests_ok; + else + error("got %d expected %d\n", r, false); +} + +void test_cmp_int(uint32_t a, uint32_t b) { if (a == b) Modified: projects/haf/trunk/maemo-launcher/launcher/test_lib.h =================================================================== --- projects/haf/trunk/maemo-launcher/launcher/test_lib.h 2008-04-15 16:06:44 UTC (rev 15409) +++ projects/haf/trunk/maemo-launcher/launcher/test_lib.h 2008-04-15 22:35:24 UTC (rev 15410) @@ -29,6 +29,8 @@ void tests_init(int total); bool tests_summary(void); +void test_success(bool r); +void test_failure(bool r); void test_cmp_int(uint32_t a, uint32_t b); void test_cmp_str(const char *a, const char *b);
- Previous message: [maemo-commits] r15409 - in projects/haf/trunk/hildon-1: . src
- Next message: [maemo-commits] r15411 - in projects/haf/trunk/maemo-launcher: . launcher
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]