Added more unit tests.
authorRyan C. Gordon <icculus@icculus.org>
Thu, 04 Mar 2010 23:08:13 -0800
changeset 887 d2ed72e046ad
parent 886 e597342f050b
child 888 3f13aefabfce
Added more unit tests.
unit_tests/preprocessor/errors/redefinition
unit_tests/preprocessor/errors/redefinition-file
unit_tests/preprocessor/errors/redefinition-file.correct
unit_tests/preprocessor/errors/redefinition-line
unit_tests/preprocessor/errors/redefinition-line.correct
unit_tests/preprocessor/errors/redefinition.correct
unit_tests/preprocessor/errors/undef-file
unit_tests/preprocessor/errors/undef-file-twice
unit_tests/preprocessor/errors/undef-file-twice.correct
unit_tests/preprocessor/errors/undef-file.correct
unit_tests/preprocessor/errors/undef-line
unit_tests/preprocessor/errors/undef-line-twice
unit_tests/preprocessor/errors/undef-line-twice.correct
unit_tests/preprocessor/errors/undef-line.correct
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/redefinition	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,2 @@
+#define x 1
+#define x 2
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/redefinition-file	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+#define __FILE__ 3
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/redefinition-file.correct	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+preprocessor/errors/redefinition-file:2: ERROR: '__FILE__' already defined
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/redefinition-line	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,3 @@
+#define __LINE__ "wrong"
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/redefinition-line.correct	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+preprocessor/errors/redefinition-line:2: ERROR: '__LINE__' already defined
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/redefinition.correct	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+preprocessor/errors/redefinition:3: ERROR: 'x' already defined
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/undef-file	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+#undef __FILE__
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/undef-file-twice	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,4 @@
+// this should only produce one warning.
+#undef __FILE__
+#undef __FILE__
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/undef-file-twice.correct	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+preprocessor/errors/undef-file-twice:3: ERROR: undefining "__FILE__"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/undef-file.correct	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+preprocessor/errors/undef-file:1: ERROR: undefining "__FILE__"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/undef-line	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,2 @@
+#undef __LINE__
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/undef-line-twice	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,4 @@
+// this should only produce one warning.
+#undef __LINE__
+#undef __LINE__
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/undef-line-twice.correct	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+preprocessor/errors/undef-line-twice:3: ERROR: undefining "__LINE__"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/unit_tests/preprocessor/errors/undef-line.correct	Thu Mar 04 23:08:13 2010 -0800
@@ -0,0 +1,1 @@
+preprocessor/errors/undef-line:2: ERROR: undefining "__LINE__"