jw3 commented on a change in pull request #463: URL: https://github.com/apache/incubator-daffodil/pull/463#discussion_r549490284
########## File path: daffodil-schematron/src/test/resources/xsd/extends-1.dfdl.xsd ########## @@ -0,0 +1,59 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> +<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:dfdl="http://www.ogf.org/dfdl/dfdl-1.0/" + xmlns:sch="http://purl.oclc.org/dsdl/schematron"> + + <xs:include schemaLocation="org/apache/daffodil/xsd/DFDLGeneralFormat.dfdl.xsd"/> + <xs:annotation> + <xs:appinfo source="http://www.ogf.org/dfdl/"> + <dfdl:format ref="GeneralFormat"/> + </xs:appinfo> + <xs:appinfo> + <sch:pattern> + <sch:rule abstract="true" id="blank"> + <sch:assert test="string-length(.) > 0"><sch:name/> is blank.</sch:assert> Review comment: I cant yet generate a failing test even after enabling xslt 2.0. > E.g., you cannot just type string-length(../some/path) in DFDL nor XPath 2.0 and expect it to work. You must bind a prefix (usually "fn" to namespace http://www.w3.org/2005/xpath-functions/ and use the prefix when calling the functions. In context of xpath, are you saying "must" because there is enforcement or because its good practice? Perhaps a counter example example is the GIF schema that uses unprefixed functions and enables xslt 2.0. With all that said, I think the tools are all there, the included version of schematron supports either way. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
