Test Framework for WIDL [2/2]
Dan Hipschman
dsh at linux.ucla.edu
Wed Jul 19 16:10:57 CDT 2006
This adds the ability to do "make test" in widl/tests. You need to copy
over known good output with "make expected" first (only do this on a build
with a known good version of widl). This will allow us to make bigger
changes to widl without having to worry about breaking Wine. More tests
can be added directly into widl/tests (for which the "expected" rule in
Makefile.in need not do anything).
ChangeLog:
* Add Makefile.in for tools/widl/tests
---
configure.ac | 1 +
tools/widl/tests/Makefile.in | 22 ++++++++++++++++++++++
2 files changed, 23 insertions(+), 0 deletions(-)
diff --git a/configure.ac b/configure.ac
index 861ed21..16b9560 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1841,6 +1841,7 @@ programs/wordpad/Makefile
server/Makefile
tools/Makefile
tools/widl/Makefile
+tools/widl/tests/Makefile
tools/winapi/Makefile
tools/winebuild/Makefile
tools/winedump/Makefile
diff --git a/tools/widl/tests/Makefile.in b/tools/widl/tests/Makefile.in
new file mode 100644
index 0000000..9c51a9f
--- /dev/null
+++ b/tools/widl/tests/Makefile.in
@@ -0,0 +1,22 @@
+TOPSRCDIR = @top_srcdir@
+SRCDIR = @srcdir@
+EXEEXT = @EXEEXT@
+
+WIDL = ../widl$(EXEEXT)
+TOOLTEST = $(TOPSRCDIR)/tools/tooltest
+TESTSTXT = $(SRCDIR)/tests.txt
+
+test:
+ @$(TOOLTEST) < $(TESTSTXT)
+
+ at MAKE_RULES@
+
+expected:
+ @for f in `find $(TOPSRCDIR) -name '*.idl' -print` ; do \
+ h=`echo "$$f" | sed s/\\.idl\$$/.h/` ; \
+ ok=`echo "$$h" | sed s:\^.\*/:: | sed s/\\.h\$$/.ok/` ; \
+ if test -f "$$h" ; then \
+ cp "$$f" . ; \
+ cp "$$h" "$$ok" ; \
+ fi ; \
+ done
More information about the wine-patches
mailing list