From 290fa35b8ac2147fd35d897275f0ed350739da4a Mon Sep 17 00:00:00 2001 From: tsutsumi <> Date: Fri, 20 Aug 2010 07:49:06 +0000 Subject: [PATCH] rename CCUnitTestCase to CCUnitTestFunc --- src/ccunit/CCUnitTestFailure.h | 6 +++--- src/ccunit/CCUnitTestListener.h | 8 ++++---- src/ccunit/CCUnitTestRunner.c | 8 ++++---- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/ccunit/CCUnitTestFailure.h b/src/ccunit/CCUnitTestFailure.h index f5d96f2..2ca81dc 100644 --- a/src/ccunit/CCUnitTestFailure.h +++ b/src/ccunit/CCUnitTestFailure.h @@ -1,5 +1,5 @@ /* -*- C -*- */ -/* Copyright (C) 2003 TSUTSUMI Kikuo. +/* Copyright (C) 2003, 2010 TSUTSUMI Kikuo. This file is part of the CCUnit Library. The CCUnit Library is free software; you can redistribute it and/or @@ -29,7 +29,7 @@ #define CCUNITTESTFAILURE_H #include -#include +#include /** * @ingroup ModuleHierarchy @@ -52,7 +52,7 @@ typedef struct CCUnitTestFailure const char* condstr; /**< test condition */ const char* expect; /**< expect value as string */ const char* actual; /**< actual value as string */ - const CCUnitTestCase* testCase; /**< test case object */ + const CCUnitTestFunc* testFunc; /**< test function object */ } CCUnitTestFailure; /** diff --git a/src/ccunit/CCUnitTestListener.h b/src/ccunit/CCUnitTestListener.h index 3989be8..a590302 100644 --- a/src/ccunit/CCUnitTestListener.h +++ b/src/ccunit/CCUnitTestListener.h @@ -1,5 +1,5 @@ /* -*- mode: C; -*- */ -/* Copyright (C) 2003 TSUTSUMI Kikuo. +/* Copyright (C) 2003, 2010 TSUTSUMI Kikuo. This file is part of the CCUnit Library. The CCUnit Library is free software; you can redistribute it and/or @@ -30,7 +30,7 @@ #include #include -#include +#include /** * @ingroup ModuleHierarchy @@ -76,12 +76,12 @@ struct CCUnitTestListener /** * A test started. */ - void (*startTest) (CCUnitTestListener* listener, CCUnitTestCase* testCase); + void (*startTest) (CCUnitTestListener* listener, CCUnitTestFunc* testFunc); /** * A test ended. */ - void (*endTest) (CCUnitTestListener* listener, CCUnitTestCase* testCase); + void (*endTest) (CCUnitTestListener* listener, CCUnitTestFunc* testFunc); }; /** @} */ diff --git a/src/ccunit/CCUnitTestRunner.c b/src/ccunit/CCUnitTestRunner.c index 793f1f8..c1eac7d 100644 --- a/src/ccunit/CCUnitTestRunner.c +++ b/src/ccunit/CCUnitTestRunner.c @@ -1,4 +1,4 @@ -/* Copyright (C) 2003 TSUTSUMI Kikuo. +/* Copyright (C) 2003, 2010 TSUTSUMI Kikuo. This file is part of the CCUnit Library. The CCUnit Library is free software; you can redistribute it and/or @@ -39,7 +39,7 @@ * @param listener notification listener. * @param test starting test case */ -static void startTest (CCUnitTestListener* listener, CCUnitTestCase* test) +static void startTest (CCUnitTestListener* listener, CCUnitTestFunc* test) { CCUnitTestRunner* runner = (CCUnitTestRunner*)listener; fputc ('.', runner->ofp); @@ -50,7 +50,7 @@ static void startTest (CCUnitTestListener* listener, CCUnitTestCase* test) * @param listener notification listener. * @param test ended test case */ -static void endTest (CCUnitTestListener* listener, CCUnitTestCase* test) +static void endTest (CCUnitTestListener* listener, CCUnitTestFunc* test) { } @@ -118,7 +118,7 @@ static void printFailures (CCUnitTestRunner* runner, CCUnitTestResult* result) { fprintf (runner->ofp, "%s:%u: %s:\n\t%s\n", f->file, f->line, - f->testCase != NULL ? f->testCase->desc : "", + f->testFunc != NULL ? f->testFunc->desc : "", f->condstr); if (f->expect || f->actual) fprintf (runner->ofp, "\texpect: %s\n\tactual: %s\n", f->expect, f->actual); -- 2.11.0