From 5e527213a2430bb3018e5eebd909aef294edf9b5 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Fri, 18 Dec 2020 18:48:46 +0300 Subject: Switch to build2 --- xsd-tests/cxx/parser/generated-impl/.gitignore | 2 + xsd-tests/cxx/parser/generated-impl/buildfile | 31 +++++ xsd-tests/cxx/parser/generated-impl/output | 122 ++++++++++++++++++ xsd-tests/cxx/parser/generated-impl/test.xml | 168 +++++++++++++++++++++++++ xsd-tests/cxx/parser/generated-impl/test.xsd | 142 +++++++++++++++++++++ 5 files changed, 465 insertions(+) create mode 100644 xsd-tests/cxx/parser/generated-impl/.gitignore create mode 100644 xsd-tests/cxx/parser/generated-impl/buildfile create mode 100644 xsd-tests/cxx/parser/generated-impl/output create mode 100644 xsd-tests/cxx/parser/generated-impl/test.xml create mode 100644 xsd-tests/cxx/parser/generated-impl/test.xsd (limited to 'xsd-tests/cxx/parser/generated-impl') diff --git a/xsd-tests/cxx/parser/generated-impl/.gitignore b/xsd-tests/cxx/parser/generated-impl/.gitignore new file mode 100644 index 0000000..21b434c --- /dev/null +++ b/xsd-tests/cxx/parser/generated-impl/.gitignore @@ -0,0 +1,2 @@ +test-pimpl.?xx +test-driver.?xx diff --git a/xsd-tests/cxx/parser/generated-impl/buildfile b/xsd-tests/cxx/parser/generated-impl/buildfile new file mode 100644 index 0000000..8710a77 --- /dev/null +++ b/xsd-tests/cxx/parser/generated-impl/buildfile @@ -0,0 +1,31 @@ +# file : cxx/parser/generated-impl/buildfile +# license : GNU GPL v2 + exceptions; see accompanying LICENSE file + +import libs = libxsd%lib{xsd} +import libs += libxerces-c%lib{xerces-c} + +exe{driver}: {hxx ixx cxx}{test-pskel} \ + {hxx cxx}{test-pimpl} \ + { cxx}{test-driver} \ + $libs + +exe{driver}: xml{test}: test.input = true +exe{driver}: file{output}: test.stdout = true + +<{hxx ixx cxx}{test-pskel} \ + {hxx cxx}{test-pimpl} \ + { cxx}{test-driver}>: xsd{test} $xsd +{{ + diag xsd ($<[0]) # @@ TMP + + $xsd cxx-parser --std c++11 \ + --generate-inline \ + --skel-file-suffix -pskel \ + --generate-print-impl \ + --generate-test-driver \ + --force-overwrite \ + --output-dir $out_base \ + $path($<[0]) +}} + +cxx.poptions =+ "-I$out_base" diff --git a/xsd-tests/cxx/parser/generated-impl/output b/xsd-tests/cxx/parser/generated-impl/output new file mode 100644 index 0000000..7c58647 --- /dev/null +++ b/xsd-tests/cxx/parser/generated-impl/output @@ -0,0 +1,122 @@ +gender: male +foo: foo +gender: male +int: 0 +int: 1 +int: 2 +int: 3 +foo: foo +int: 3 +int: 2 +int: 1 +int: 0 +union: 9 +foo: foo +union: string +x: x +a: aaa +x: x +y: y +a: aaa +b: bbb +boolean: 1 +boolean: 0 +boolean: 1 +boolean: 0 +byte: 0 +byte: 123 +byte: -123 +unsigned-byte: 0 +unsigned-byte: 123 +short: 0 +short: -1234 +short: 1234 +unsigned-short: 0 +unsigned-short: 1234 +int: 0 +int: -12345 +int: 12345 +unsigned-int: 0 +unsigned-int: 12345 +long: 0 +long: -123456 +long: 123456 +unsigned-long: 0 +unsigned-long: 123456 +integer: 0 +integer: -123456 +integer: 123456 +negative-integer: -123456 +non-positive-integer: 0 +non-positive-integer: -123456 +positive-integer: 123456 +non-negative-integer: 0 +non-negative-integer: 123456 +float: 0 +float: 1.123 +float: -1.123 +double: 0 +double: 1.1234 +double: -1.1234 +decimal: 0 +decimal: 1.1234 +decimal: -1.1234 +string: string space newline +normalized-string: string space newline +token: string space newline +name: as123:345-.abs +nmtoken: 1as123:345-.abs +nmtokens: abc 123 +ncname: as123_345-.abs +id: abc +id: a123 +idref: abc +idrefs: abc a123 +language: en +language: en-us +uri: http://www.example.com/foo#bar +qname: schemaLocation +qname: xsi:schemaLocation +base64_binary: 10 bytes +base64_binary: 1 bytes +base64_binary: 2 bytes +base64_binary: 3 bytes +hex_binary: 0 bytes +hex_binary: 10 bytes +gday: ---12+12:0 +gday: ---1 +gday: ---31 +gday: ---15+0:0 +gday: ---15-14:0 +gmonth: --10+12:0 +gmonth: --1 +gmonth: --12+0:0 +gyear: 2007+12:0 +gyear: 1 +gyear: -20000+0:0 +gmonth_day: --10-28+12:0 +gmonth_day: --12-31 +gmonth_day: --1-1+0:0 +gyear_month: 2007-12+12:0 +gyear_month: -2007-10 +gyear_month: 20007-10+0:0 +gyear_month: -20007-1 +date: 2007-12-26+12:0 +date: -2007-10-15 +date: 20007-12-31+0:0 +date: -20007-1-1 +time: 12:46:23.456+12:0 +time: 12:13:14 +time: 12:13:14+0:0 +date_time: 2007-12-26T12:13:14.123+12:0 +date_time: -2007-10-15T12:13:14 +date_time: 20007-12-31T12:13:14+0:0 +date_time: -20007-1-1T12:13:14 +duration: -P2007Y13M32DT25H61M61.123S +duration: P1Y0M0DT0H0M0S +duration: P0Y1M0DT0H0M0S +duration: P0Y0M1DT0H0M0S +duration: P0Y0M0DT1H0M0S +duration: P0Y0M0DT0H1M0S +duration: P0Y0M0DT0H0M1.1S +duration: P1Y0M0DT0H0M1S diff --git a/xsd-tests/cxx/parser/generated-impl/test.xml b/xsd-tests/cxx/parser/generated-impl/test.xml new file mode 100644 index 0000000..2f29a39 --- /dev/null +++ b/xsd-tests/cxx/parser/generated-impl/test.xml @@ -0,0 +1,168 @@ + + + male + male + + 0 1 2 3 + 3 2 1 0 + + 9 + string + + + aaa + + + + aaa + bbb + + + aaabbbccc + abc123 + + 1 + 0 + true + false + + 0 + 123 + -123 + + 0 + 123 + + 0 + -1234 + 1234 + + 0 + 1234 + + 0 + -12345 + 12345 + + 0 + 12345 + + 0 + -123456 + 123456 + + 0 + 123456 + + 0 + -123456 + 123456 + + -123456 + + 0 + -123456 + + 123456 + + 0 + 123456 + + 0 + 1.123 + -1.123 + + 0 + 1.1234 + -1.1234 + + 0 + 1.1234 + -1.1234 + + string space newline + + string space newline + + string space newline + + as123:345-.abs + + 1as123:345-.abs + + abc 123 + + as123_345-.abs + + abc + a123 + + abc + + abc a123 + + en + en-us + + http://www.example.com/foo#bar + + schemaLocation + xsi:schemaLocation + + MTIzNDVhYmNqaw== + YQ== + YWI= + YWJj + + + 31323334356162636a6b + + ---12+12:00 + ---01 + ---31 + ---15Z + ---15-14:00 + + --10+12:00 + --01 + --12Z + + 2007+12:00 + 0001 + -20000Z + + --10-28+12:00 + --12-31 + --01-01Z + + 2007-12+12:00 + -2007-10 + 20007-10Z + -20007-01 + + 2007-12-26+12:00 + -2007-10-15 + 20007-12-31Z + -20007-01-01 + + + + + + 2007-12-26T12:13:14.123+12:00 + -2007-10-15T12:13:14 + 20007-12-31T12:13:14Z + -20007-01-01T12:13:14 + + -P2007Y13M32DT25H61M61.123S + P1Y + P1M + P1D + PT1H + PT1M + PT1.1S + P1YT1S + + diff --git a/xsd-tests/cxx/parser/generated-impl/test.xsd b/xsd-tests/cxx/parser/generated-impl/test.xsd new file mode 100644 index 0000000..7bc8f23 --- /dev/null +++ b/xsd-tests/cxx/parser/generated-impl/test.xsd @@ -0,0 +1,142 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- cgit v1.1