Correcting unit test makefiles. Corrected error in config.h for BACAPP NULL values.

This commit is contained in:
skarg
2007-10-29 13:58:05 +00:00
parent 39f0a6f876
commit cf5587c29d
7 changed files with 59 additions and 56 deletions
+1
View File
@@ -68,6 +68,7 @@
/* BACAPP decodes WriteProperty service requests /* BACAPP decodes WriteProperty service requests
Choose the datatypes that your application supports */ Choose the datatypes that your application supports */
#if defined (BACAPP_ALL) #if defined (BACAPP_ALL)
#define BACAPP_NULL
#define BACAPP_BOOLEAN #define BACAPP_BOOLEAN
#define BACAPP_UNSIGNED #define BACAPP_UNSIGNED
#define BACAPP_SIGNED #define BACAPP_SIGNED
+2 -2
View File
@@ -912,7 +912,6 @@ bool bacapp_same_value(BACNET_APPLICATION_DATA_VALUE * value,
BACNET_APPLICATION_DATA_VALUE * test_value) BACNET_APPLICATION_DATA_VALUE * test_value)
{ {
bool status = false; /*return value */ bool status = false; /*return value */
bool tag
/* does the tag match? */ /* does the tag match? */
if (test_value->tag == value->tag) if (test_value->tag == value->tag)
@@ -1172,7 +1171,8 @@ void testBACnetApplicationData(Test * pTest)
status = bacapp_parse_application_data(BACNET_APPLICATION_TAG_NULL, status = bacapp_parse_application_data(BACNET_APPLICATION_TAG_NULL,
NULL, &value); NULL, &value);
ct_test(pTest, status == true); ct_test(pTest, status == true);
ct_test(pTest, testBACnetApplicationDataValue(&value)); status = testBACnetApplicationDataValue(&value);
ct_test(pTest, status == true);
status = bacapp_parse_application_data(BACNET_APPLICATION_TAG_BOOLEAN, status = bacapp_parse_application_data(BACNET_APPLICATION_TAG_BOOLEAN,
"1", &value); "1", &value);
+9 -10
View File
@@ -1,18 +1,17 @@
#Makefile to build test case #Makefile to build test case
CC = gcc CC = gcc
BASEDIR = . SRC_DIR = ../src
#CFLAGS = -Wall -I. INCLUDES = -I../include -I.
# -g for debugging with gdb DEFINES = -DBIG_ENDIAN=0 -DTEST -DTEST_ABORT
#CFLAGS = -Wall -I. -g
CFLAGS = -Wall -Iinclude -Itest -DBIG_ENDIAN=0 -DTEST -DTEST_ABORT -g
SRC_DIR = src CFLAGS = -Wall $(INCLUDES) $(DEFINES) -g
SRCS = $(SRC_DIR)/bacdcode.c \ SRCS = $(SRC_DIR)/bacdcode.c \
$(SRC_DIR)/bacint.c \ $(SRC_DIR)/bacint.c \
$(SRC_DIR)/bacstr.c \ $(SRC_DIR)/bacstr.c \
$(SRC_DIR)/abort.c \ $(SRC_DIR)/bacreal.c \
test/ctest.c $(SRC_DIR)/abort.c \
ctest.c
TARGET = abort TARGET = abort
+8 -8
View File
@@ -1,14 +1,14 @@
#Makefile to build test case #Makefile to build test case
CC = gcc CC = gcc
BASEDIR = . SRC_DIR = ../src
#CFLAGS = -Wall -I. INCLUDES = -I../include -I.
# -g for debugging with gdb DEFINES = -DBIG_ENDIAN=0 -DTEST -DTEST_ADDRESS
#CFLAGS = -Wall -I. -g
CFLAGS = -Wall -Iinclude -Itest -DTEST -DTEST_ADDRESS -g
SRCS = src/address.c \ CFLAGS = -Wall $(INCLUDES) $(DEFINES) -g
src/bacaddr.c \
test/ctest.c SRCS = $(SRC_DIR)/address.c \
$(SRC_DIR)/bacaddr.c \
ctest.c
OBJS = ${SRCS:.c=.o} OBJS = ${SRCS:.c=.o}
+9 -9
View File
@@ -1,16 +1,16 @@
#Makefile to build test case #Makefile to build test case
CC = gcc CC = gcc
BASEDIR = . SRC_DIR = ../src
# -g for debugging with gdb INCLUDES = -I../include -I. -I../demo/object
DEFINES = -DBACFILE=1 -DBACDL_BIP=1 -DBIG_ENDIAN=0 -DTEST -DTEST_ATOMIC_READ_FILE DEFINES = -DBACFILE=1 -DBIG_ENDIAN=0 -DTEST -DTEST_ATOMIC_READ_FILE
INCLUDES = -Iinclude -Idemo/object -Itest
CFLAGS = -Wall $(INCLUDES) $(DEFINES) -g CFLAGS = -Wall $(INCLUDES) $(DEFINES) -g
SRCS = src/bacdcode.c \ SRCS = $(SRC_DIR)/bacdcode.c \
src/bacint.c \ $(SRC_DIR)/bacint.c \
src/bacstr.c \ $(SRC_DIR)/bacstr.c \
src/arf.c \ $(SRC_DIR)/bacreal.c \
test/ctest.c $(SRC_DIR)/arf.c \
ctest.c
OBJS = ${SRCS:.c=.o} OBJS = ${SRCS:.c=.o}
+9 -8
View File
@@ -1,16 +1,17 @@
#Makefile to build test case #Makefile to build test case
CC = gcc CC = gcc
BASEDIR = .
DEFINES = -DBACFILE=1 -DBACDL_BIP=1 -DBIG_ENDIAN=0 -DTEST -DTEST_ATOMIC_WRITE_FILE SRC_DIR = ../src
INCLUDES = -Iinclude -Idemo/object -Itest INCLUDES = -I../include -I. -I../demo/object
DEFINES = -DBACFILE=1 -DBIG_ENDIAN=0 -DTEST -DTEST_ATOMIC_WRITE_FILE
CFLAGS = -Wall $(INCLUDES) $(DEFINES) -g CFLAGS = -Wall $(INCLUDES) $(DEFINES) -g
SRCS = src/bacdcode.c \ SRCS = $(SRC_DIR)/bacdcode.c \
src/bacint.c \ $(SRC_DIR)/bacint.c \
src/bacstr.c \ $(SRC_DIR)/bacstr.c \
src/awf.c \ $(SRC_DIR)/bacreal.c \
test/ctest.c $(SRC_DIR)/awf.c \
ctest.c
OBJS = ${SRCS:.c=.o} OBJS = ${SRCS:.c=.o}
+15 -13
View File
@@ -1,19 +1,21 @@
#Makefile to build test case #Makefile to build test case
CC = gcc CC = gcc
BASEDIR = .
#CFLAGS = -Wall -I.
# -g for debugging with gdb
DEFINES = -DBIG_ENDIAN=0 -DTEST -DTEST_BACNET_APPLICATION_DATA
CFLAGS = -Wall -Iinclude -Itest -g $(DEFINES)
SRCS = src/bacdcode.c \ SRC_DIR = ../src
src/bacint.c \ INCLUDES = -I../include -I.
src/bacstr.c \ DEFINES = -DBIG_ENDIAN=0 -DTEST -DBACAPP_ALL -DTEST_BACNET_APPLICATION_DATA
src/bacapp.c \
src/datetime.c \ CFLAGS = -Wall $(INCLUDES) $(DEFINES) -g
src/bactext.c \
src/indtext.c \ SRCS = $(SRC_DIR)/bacdcode.c \
test/ctest.c $(SRC_DIR)/bacint.c \
$(SRC_DIR)/bacstr.c \
$(SRC_DIR)/bacreal.c \
$(SRC_DIR)/bacapp.c \
$(SRC_DIR)/datetime.c \
$(SRC_DIR)/bactext.c \
$(SRC_DIR)/indtext.c \
ctest.c
OBJS = ${SRCS:.c=.o} OBJS = ${SRCS:.c=.o}