]> pd.if.org Git - pdclib/commitdiff
Moved test-related files to testing subdirectory (i.e., out of the way).
authorsolar <unknown>
Mon, 19 Jul 2010 09:47:39 +0000 (09:47 +0000)
committersolar <unknown>
Mon, 19 Jul 2010 09:47:39 +0000 (09:47 +0000)
Makefile
testing/_PDCLIB_test.h [moved from internals/_PDCLIB_test.h with 100% similarity]
testing/fprintf_reftest.incl [moved from functions/stdio/fprintf_reftest.incl with 83% similarity]
testing/fscan_sources.incl [moved from functions/stdio/fscan_sources.incl with 84% similarity]
testing/printf_reference.txt [moved from functions/stdio/printf_reference.txt with 100% similarity]
testing/printf_testcases.incl [moved from functions/stdio/printf_testcases.incl with 100% similarity]
testing/scan_test.h [moved from functions/stdio/scan_test.h with 100% similarity]
testing/scanf_testcases.incl [moved from functions/stdio/scanf_testcases.incl with 100% similarity]
testing/sscan_sources.incl [moved from functions/stdio/sscan_sources.incl with 100% similarity]

index 6748be49117d6479ec9f239b256b2c7eb5efdf7a..0acd1cc6132e91de48c5445930759832302f499b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -33,7 +33,7 @@ PATCHFILES2 := $(shell ls platform/$(PLATFORM)/functions/stdlib/*.c)
 PATCHFILES3 := $(shell ls platform/$(PLATFORM)/functions/stdio/*.c)
 
 WARNINGS := -Wall -Wextra -pedantic -Wno-unused-parameter -Wshadow -Wpointer-arith -Wcast-align -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wnested-externs -Winline -Wno-long-long -fno-builtin 
-CFLAGS := -g -std=c99 -I./internals $(WARNINGS) $(USERFLAGS)
+CFLAGS := -g -std=c99 -I./internals -I./testing $(WARNINGS) $(USERFLAGS)
 
 .PHONY: all clean srcdist bindist test tests testdrivers regtests regtestdrivers todos fixmes find links unlink help
 
similarity index 83%
rename from functions/stdio/fprintf_reftest.incl
rename to testing/fprintf_reftest.incl
index afc89b97513c8086bd0b0cd632c31f5cad26d9ec..05c74c2025bea45929e9b022d7a4abe403ffaca7 100644 (file)
@@ -5,7 +5,7 @@
     TESTCASE( ( buffer = fopen( "testfile", "r" ) ) != NULL );
     readcounter = fread( readbuffer, 1, 2000, buffer );
     TESTCASE( fclose( buffer ) == 0 );
-    TESTCASE( ( buffer = fopen( "functions/stdio/printf_reference.txt", "r" ) ) != NULL );
+    TESTCASE( ( buffer = fopen( "testing/printf_reference.txt", "r" ) ) != NULL );
     TESTCASE( fread( refbuffer, 1, 2000, buffer ) == readcounter );
     TESTCASE( fclose( buffer ) == 0 );
     TESTCASE( memcmp( readbuffer, refbuffer, readcounter ) == 0 );
similarity index 84%
rename from functions/stdio/fscan_sources.incl
rename to testing/fscan_sources.incl
index 704c5428e8065e38cf67217694fe20393cac3fa6..a7dc18b71a47e4dcc59badb49085e3d9973c7bd1 100644 (file)
@@ -1,9 +1,9 @@
-    FILE * general = fopen( "scanf_testdata_general", "wb+" );
+    FILE * general = fopen( "testing/scanf_testdata_general", "wb+" );
     TESTCASE( general != NULL );
     TESTCASE( fwrite( "12345678901\0003-5+7\0009\3772 4 6 8 0\3771 \011 5%%  0", 1, 40, general ) == 40 );
     rewind( general );
 
-    FILE * decimal = fopen( "scanf_testdata_decimal", "wb+" );
+    FILE * decimal = fopen( "testing/scanf_testdata_decimal", "wb+" );
     TESTCASE( decimal != NULL );
     TESTCASE( fwrite( "-0 +0 -128 +127 +255 -32768 +32767 +65535\n"
                       "-2147483648 +2147483647 +4294967295\n"
@@ -11,7 +11,7 @@
                       "+18446744073709551615\n", 1, 142, decimal ) == 142 );
     rewind( decimal );
 
-    FILE * hexadecimal = fopen( "scanf_testdata_hexadecimal", "wb+" );
+    FILE * hexadecimal = fopen( "testing/scanf_testdata_hexadecimal", "wb+" );
     TESTCASE( hexadecimal != NULL );
     TESTCASE( fwrite( "-0x0 -0x000 -0x7f -0x80 0xff -0x7fff -0x8000\n"
                       "0xffff -0x7fffffff -0x80000000 0xffffffff\n"
@@ -19,7 +19,7 @@
                       "0xffffffffffffffff\n", 1, 146, hexadecimal ) == 146 );
     rewind( hexadecimal );
 
-    FILE * octal = fopen( "scanf_testdata_octal", "wb+" );
+    FILE * octal = fopen( "testing/scanf_testdata_octal", "wb+" );
     TESTCASE( octal != NULL );
     TESTCASE( fwrite( "+0000 -0000 +0177 +0377 -0377 +077777 +0177777\n"
                       "-0177777 +017777777777 +037777777777\n"
                       "-01777777777777777777777\n", 1, 172, octal ) == 172 );
     rewind( octal );
 
-    FILE * alpha = fopen( "scanf_testdata_alpha", "wb+" );
+    FILE * alpha = fopen( "testing/scanf_testdata_alpha", "wb+" );
     TESTCASE( alpha != NULL );
     TESTCASE( fwrite( "abcdefgh-ijklmnop[qrs%uvw]xyz", 1, 29, alpha ) == 29 );
     rewind( alpha );
 
 #ifndef REGTEST
-    FILE * special = fopen( "scanf_testdata_special", "wb+" );
+    FILE * special = fopen( "testing/scanf_testdata_special", "wb+" );
     TESTCASE( special != NULL );
     TESTCASE( fwrite( "-0xz\n", 1, 5, special ) == 5 );
     rewind( special );