From a8ce5c380c69539fe0c7c62c397634d9d0c9fde2 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Fri, 18 Dec 2020 18:48:46 +0300 Subject: Switch to build2 --- tests/cxx/parser/validation/restriction/driver.cxx | 107 --------------------- tests/cxx/parser/validation/restriction/makefile | 92 ------------------ .../cxx/parser/validation/restriction/test-000.std | 0 .../cxx/parser/validation/restriction/test-000.xml | 31 ------ .../cxx/parser/validation/restriction/test-001.std | 1 - .../cxx/parser/validation/restriction/test-001.xml | 11 --- .../cxx/parser/validation/restriction/test-002.std | 1 - .../cxx/parser/validation/restriction/test-002.xml | 12 --- .../cxx/parser/validation/restriction/test-003.std | 1 - .../cxx/parser/validation/restriction/test-003.xml | 16 --- .../cxx/parser/validation/restriction/test-004.std | 1 - .../cxx/parser/validation/restriction/test-004.xml | 10 -- .../cxx/parser/validation/restriction/test-005.std | 1 - .../cxx/parser/validation/restriction/test-005.xml | 11 --- tests/cxx/parser/validation/restriction/test.xsd | 82 ---------------- 15 files changed, 377 deletions(-) delete mode 100644 tests/cxx/parser/validation/restriction/driver.cxx delete mode 100644 tests/cxx/parser/validation/restriction/makefile delete mode 100644 tests/cxx/parser/validation/restriction/test-000.std delete mode 100644 tests/cxx/parser/validation/restriction/test-000.xml delete mode 100644 tests/cxx/parser/validation/restriction/test-001.std delete mode 100644 tests/cxx/parser/validation/restriction/test-001.xml delete mode 100644 tests/cxx/parser/validation/restriction/test-002.std delete mode 100644 tests/cxx/parser/validation/restriction/test-002.xml delete mode 100644 tests/cxx/parser/validation/restriction/test-003.std delete mode 100644 tests/cxx/parser/validation/restriction/test-003.xml delete mode 100644 tests/cxx/parser/validation/restriction/test-004.std delete mode 100644 tests/cxx/parser/validation/restriction/test-004.xml delete mode 100644 tests/cxx/parser/validation/restriction/test-005.std delete mode 100644 tests/cxx/parser/validation/restriction/test-005.xml delete mode 100644 tests/cxx/parser/validation/restriction/test.xsd (limited to 'tests/cxx/parser/validation/restriction') diff --git a/tests/cxx/parser/validation/restriction/driver.cxx b/tests/cxx/parser/validation/restriction/driver.cxx deleted file mode 100644 index 6f9a871..0000000 --- a/tests/cxx/parser/validation/restriction/driver.cxx +++ /dev/null @@ -1,107 +0,0 @@ -// file : tests/cxx/parser/validation/restriction/driver.cxx -// license : GNU GPL v2 + exceptions; see accompanying LICENSE file - -// Test the restriction compositor validation. -// - -#include -#include -#include - -#include "test-pskel.hxx" - -using namespace std; -using namespace test; - -struct base_a_pimpl: base_a_pskel -{ -}; - -struct restriction_a_pimpl: restriction_a_pskel -{ -}; - -struct extension_b_pimpl: extension_b_pskel -{ -}; - -struct restriction_b_pimpl: restriction_b_pskel -{ -}; - -struct type_b_pimpl: type_b_pskel -{ -}; - -struct type_r_pimpl: type_r_pskel -{ -}; - - -int -main (int argc, char* argv[]) -{ - if (argc != 2) - { - cerr << "usage: " << argv[0] << " test.xml" << endl; - return 1; - } - - try - { - xml_schema::string_pimpl string_p; - base_a_pimpl base_a_p; - restriction_a_pimpl restriction_a_p; - extension_b_pimpl extension_b_p; - restriction_b_pimpl restriction_b_p; - type_b_pimpl type_b_p; - type_r_pimpl type_r_p; - - base_a_p.parsers (string_p, string_p, string_p, - string_p, string_p, string_p); - - restriction_a_p.parsers (string_p, string_p, string_p, - string_p, string_p, string_p); - - extension_b_p.parsers (string_p, string_p, string_p, - string_p, string_p); - - restriction_b_p.parsers (string_p, string_p, string_p, - string_p, string_p); - - type_b_p.parsers (base_a_p, extension_b_p); - type_r_p.parsers (restriction_a_p, restriction_b_p); - - xml_schema::document doc_b_p (type_b_p, "test", "root"); - xml_schema::document doc_r_p (type_r_p, "test", "root"); - - { - ifstream ifs (argv[1]); - type_b_p.pre (); - doc_b_p.parse (ifs, argv[1], "", xml_schema::flags::dont_validate); - type_b_p.post_type_b (); - } - - try - { - ifstream ifs (argv[1]); - type_r_p.pre (); - doc_r_p.parse (ifs, argv[1], "", xml_schema::flags::dont_validate); - type_r_p.post_type_r (); - } - catch (xml_schema::exception const& e) - { - cout << e << endl; - } - } - catch (xml_schema::exception const& e) - { - cerr << e << endl; - return 1; - } - catch (ios_base::failure const&) - { - cerr << "io failure" << endl; - return 1; - } -} diff --git a/tests/cxx/parser/validation/restriction/makefile b/tests/cxx/parser/validation/restriction/makefile deleted file mode 100644 index 61af2bf..0000000 --- a/tests/cxx/parser/validation/restriction/makefile +++ /dev/null @@ -1,92 +0,0 @@ -# file : tests/cxx/parser/validation/restriction/makefile -# license : GNU GPL v2 + exceptions; see accompanying LICENSE file - -include $(dir $(lastword $(MAKEFILE_LIST)))../../../../../build/bootstrap.make - -xsd := test.xsd -cxx := driver.cxx - -tests := 000 001 002 003 004 005 - -obj := $(addprefix $(out_base)/,$(cxx:.cxx=.o) $(xsd:.xsd=-pskel.o)) -dep := $(obj:.o=.o.d) - -driver := $(out_base)/driver -test := $(out_base)/.test -clean := $(out_base)/.clean - -# Import. -# -$(call import,\ - $(scf_root)/import/libxerces-c/stub.make,\ - l: xerces_c.l,cpp-options: xerces_c.l.cpp-options) - -# Build. -# -$(driver): $(obj) $(xerces_c.l) - -$(obj) $(dep): cpp_options := -I$(out_base) -I$(src_base) -I$(src_root)/libxsd -$(obj) $(dep): $(xerces_c.l.cpp-options) - -genf := $(xsd:.xsd=-pskel.hxx) $(xsd:.xsd=-pskel.ixx) $(xsd:.xsd=-pskel.cxx) -gen := $(addprefix $(out_base)/,$(genf)) - -$(gen): xsd := $(out_root)/xsd/xsd -$(gen): xsd_options += --generate-validation -$(gen): $(out_root)/xsd/xsd - -$(call include-dep,$(dep),$(obj),$(gen)) - - -# Convenience alias for default target. -# -$(out_base)/: $(driver) - - -# Test. -# -test_targets := $(addprefix $(out_base)/.test-,$(tests)) - -$(test): $(test_targets) -$(test_targets): driver := $(driver) - -.PHONY: $(out_base)/.test-% -$(out_base)/.test-%: $(driver) $(src_base)/test.xsd $(src_base)/test-%.xml $(src_base)/test-%.std - $(call message,test $(out_base)/$*,$(driver) $(src_base)/test-$*.xml | diff -u $(src_base)/test-$*.std -) - - -# Clean. -# -$(clean): $(driver).o.clean \ - $(addsuffix .cxx.clean,$(obj)) \ - $(addsuffix .cxx.clean,$(dep)) \ - $(addprefix $(out_base)/,$(xsd:.xsd=-pskel.cxx.xsd.clean)) - -# Generated .gitignore. -# -ifeq ($(out_base),$(src_base)) -$(gen): | $(out_base)/.gitignore -$(driver): | $(out_base)/.gitignore - -$(out_base)/.gitignore: files := driver $(genf) -$(clean): $(out_base)/.gitignore.clean - -$(call include,$(bld_root)/git/gitignore.make) -endif - -# How to. -# -$(call include,$(bld_root)/cxx/o-e.make) -$(call include,$(bld_root)/cxx/cxx-o.make) -$(call include,$(bld_root)/cxx/cxx-d.make) - -$(call include,$(bld_root)/cxx/standard.make) # cxx_standard -ifdef cxx_standard -$(gen): xsd_options += --std $(cxx_standard) -$(call include,$(scf_root)/xsd/parser/xsd-cxx.make) -endif - - -# Dependencies. -# -$(call import,$(src_root)/xsd/makefile) diff --git a/tests/cxx/parser/validation/restriction/test-000.std b/tests/cxx/parser/validation/restriction/test-000.std deleted file mode 100644 index e69de29..0000000 diff --git a/tests/cxx/parser/validation/restriction/test-000.xml b/tests/cxx/parser/validation/restriction/test-000.xml deleted file mode 100644 index 21402b4..0000000 --- a/tests/cxx/parser/validation/restriction/test-000.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - a - b - c - - - - a - b - c - - - - a - b - - - - a - c - - - - a - - - diff --git a/tests/cxx/parser/validation/restriction/test-001.std b/tests/cxx/parser/validation/restriction/test-001.std deleted file mode 100644 index 5077837..0000000 --- a/tests/cxx/parser/validation/restriction/test-001.std +++ /dev/null @@ -1 +0,0 @@ -:7:8 error: expected element 'a' instead of 'b' diff --git a/tests/cxx/parser/validation/restriction/test-001.xml b/tests/cxx/parser/validation/restriction/test-001.xml deleted file mode 100644 index 4015302..0000000 --- a/tests/cxx/parser/validation/restriction/test-001.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - b - c - - - diff --git a/tests/cxx/parser/validation/restriction/test-002.std b/tests/cxx/parser/validation/restriction/test-002.std deleted file mode 100644 index f12c342..0000000 --- a/tests/cxx/parser/validation/restriction/test-002.std +++ /dev/null @@ -1 +0,0 @@ -:10:19 error: expected attribute 'z' diff --git a/tests/cxx/parser/validation/restriction/test-002.xml b/tests/cxx/parser/validation/restriction/test-002.xml deleted file mode 100644 index eb7684c..0000000 --- a/tests/cxx/parser/validation/restriction/test-002.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - a - b - c - - - diff --git a/tests/cxx/parser/validation/restriction/test-003.std b/tests/cxx/parser/validation/restriction/test-003.std deleted file mode 100644 index 0c65175..0000000 --- a/tests/cxx/parser/validation/restriction/test-003.std +++ /dev/null @@ -1 +0,0 @@ -:11:8 error: unexpected element 'a' diff --git a/tests/cxx/parser/validation/restriction/test-003.xml b/tests/cxx/parser/validation/restriction/test-003.xml deleted file mode 100644 index 49f18c7..0000000 --- a/tests/cxx/parser/validation/restriction/test-003.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - a - b - c - - a - b - c - - - diff --git a/tests/cxx/parser/validation/restriction/test-004.std b/tests/cxx/parser/validation/restriction/test-004.std deleted file mode 100644 index 5077837..0000000 --- a/tests/cxx/parser/validation/restriction/test-004.std +++ /dev/null @@ -1 +0,0 @@ -:7:8 error: expected element 'a' instead of 'b' diff --git a/tests/cxx/parser/validation/restriction/test-004.xml b/tests/cxx/parser/validation/restriction/test-004.xml deleted file mode 100644 index 115cd38..0000000 --- a/tests/cxx/parser/validation/restriction/test-004.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - b - - - diff --git a/tests/cxx/parser/validation/restriction/test-005.std b/tests/cxx/parser/validation/restriction/test-005.std deleted file mode 100644 index e92de14..0000000 --- a/tests/cxx/parser/validation/restriction/test-005.std +++ /dev/null @@ -1 +0,0 @@ -:9:19 error: expected attribute 'y' diff --git a/tests/cxx/parser/validation/restriction/test-005.xml b/tests/cxx/parser/validation/restriction/test-005.xml deleted file mode 100644 index e9ab7d9..0000000 --- a/tests/cxx/parser/validation/restriction/test-005.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - a - b - - - diff --git a/tests/cxx/parser/validation/restriction/test.xsd b/tests/cxx/parser/validation/restriction/test.xsd deleted file mode 100644 index 158ded5..0000000 --- a/tests/cxx/parser/validation/restriction/test.xsd +++ /dev/null @@ -1,82 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -- cgit v1.1