markdown 一份报告显示了eXist实现XPath&XQuery函数和运算符规范中的函数签名不匹配
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了markdown 一份报告显示了eXist实现XPath&XQuery函数和运算符规范中的函数签名不匹配相关的知识,希望对你有一定的参考价值。
<?xml version="1.0" encoding="UTF-8"?>
<signature-mismatches>
<testcase name="array_append_2">
<name>array:append#2</name>
<arg>array(*)</arg>
<arg>item()*</arg>
<return>
<expected>array(*)</expected>
<actual>array(*)*</actual>
</return>
</testcase>
<testcase name="array_filter_2">
<name>array:filter#2</name>
<arg>array(*)</arg>
<arg>
<expected>function(item()*) as xs:boolean</expected>
<actual>function(*)</actual>
</arg>
<return>array(*)</return>
</testcase>
<testcase name="array_fold-left_3">
<name>array:fold-left#3</name>
<arg>array(*)</arg>
<arg>item()*</arg>
<arg>
<expected>function(item()*, item()*) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="array_fold-right_3">
<name>array:fold-right#3</name>
<arg>array(*)</arg>
<arg>item()*</arg>
<arg>
<expected>function(item()*, item()*) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="array_for-each-pair_3">
<name>array:for-each-pair#3</name>
<arg>array(*)</arg>
<arg>array(*)</arg>
<arg>
<expected>function(item()*, item()*) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>array(*)</return>
</testcase>
<testcase name="array_for-each_2">
<name>array:for-each#2</name>
<arg>array(*)</arg>
<arg>
<expected>function(item()*) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>array(*)</return>
</testcase>
<testcase name="array_get_2">
<name>array:get#2</name>
<arg>array(*)</arg>
<arg>xs:integer</arg>
<return>
<expected>item()*</expected>
<actual>xs:integer*</actual>
</return>
</testcase>
<testcase name="array_remove_2">
<name>array:remove#2</name>
<arg>array(*)</arg>
<arg>
<expected>xs:integer*</expected>
<actual>xs:integer</actual>
</arg>
<return>array(*)</return>
</testcase>
<testcase name="fn_abs_1">
<name>abs#1</name>
<arg>xs:numeric?</arg>
<return>
<expected>xs:numeric?</expected>
<actual>xs:numeric</actual>
</return>
</testcase>
<testcase name="fn_analyze-string_2">
<name>analyze-string#2</name>
<arg>xs:string?</arg>
<arg>xs:string</arg>
<return>
<expected>element(fn:analyze-string-result)</expected>
<actual>element()</actual>
</return>
</testcase>
<testcase name="fn_analyze-string_3">
<name>analyze-string#3</name>
<arg>xs:string?</arg>
<arg>xs:string</arg>
<arg>xs:string</arg>
<return>
<expected>element(fn:analyze-string-result)</expected>
<actual>element()</actual>
</return>
</testcase>
<testcase name="fn_ceiling_1">
<name>ceiling#1</name>
<arg>xs:numeric?</arg>
<return>
<expected>xs:numeric?</expected>
<actual>xs:numeric</actual>
</return>
</testcase>
<testcase name="fn_collection_0">
<name>collection#0</name>
<return>
<expected>item()*</expected>
<actual>node()*</actual>
</return>
</testcase>
<testcase name="fn_collection_1">
<name>collection#1</name>
<arg>
<expected>xs:string?</expected>
<actual>xs:string*</actual>
</arg>
<return>
<expected>item()*</expected>
<actual>node()*</actual>
</return>
</testcase>
<testcase name="fn_concat_3">
<name>concat#3</name>
<arg>xs:anyAtomicType?</arg>
<arg>xs:anyAtomicType?</arg>
<arg>xs:anyAtomicType?</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_current-dateTime_0">
<name>current-dateTime#0</name>
<return>
<expected>xs:dateTimeStamp</expected>
<actual>xs:dateTime</actual>
</return>
</testcase>
<testcase name="fn_days-from-duration_1">
<name>days-from-duration#1</name>
<arg>
<expected>xs:duration?</expected>
<actual>xs:dayTimeDuration?</actual>
</arg>
<return>xs:integer?</return>
</testcase>
<testcase name="fn_ends-with_3">
<name>ends-with#3</name>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<arg>xs:string</arg>
<return>
<expected>xs:boolean</expected>
<actual>xs:boolean?</actual>
</return>
</testcase>
<testcase name="fn_environment-variable_1">
<name>environment-variable#1</name>
<arg>xs:string</arg>
<return>
<expected>xs:string?</expected>
<actual>xs:stringempty-sequence()</actual>
</return>
</testcase>
<testcase name="fn_error_0">
<name>error#0</name>
<return>
<expected>none</expected>
<actual>empty-sequence()empty-sequence()</actual>
</return>
</testcase>
<testcase name="fn_error_1">
<name>error#1</name>
<arg>
<expected>xs:QName?</expected>
<actual>xs:QName</actual>
</arg>
<return>
<expected>none</expected>
<actual>empty-sequence()empty-sequence()</actual>
</return>
</testcase>
<testcase name="fn_error_2">
<name>error#2</name>
<arg>xs:QName?</arg>
<arg>xs:string</arg>
<return>
<expected>none</expected>
<actual>empty-sequence()empty-sequence()</actual>
</return>
</testcase>
<testcase name="fn_error_3">
<name>error#3</name>
<arg>xs:QName?</arg>
<arg>xs:string</arg>
<arg>item()*</arg>
<return>
<expected>none</expected>
<actual>empty-sequence()empty-sequence()</actual>
</return>
</testcase>
<testcase name="fn_filter_2">
<name>filter#2</name>
<arg>item()*</arg>
<arg>
<expected>function(item()) as xs:boolean</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="fn_floor_1">
<name>floor#1</name>
<arg>
<expected>xs:numeric?</expected>
<actual>xs:numeric*</actual>
</arg>
<return>
<expected>xs:numeric?</expected>
<actual>xs:numeric</actual>
</return>
</testcase>
<testcase name="fn_fold-left_3">
<name>fold-left#3</name>
<arg>item()*</arg>
<arg>item()*</arg>
<arg>
<expected>function(item()*, item()) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="fn_fold-right_3">
<name>fold-right#3</name>
<arg>item()*</arg>
<arg>item()*</arg>
<arg>
<expected>function(item(), item()*) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="fn_for-each-pair_3">
<name>for-each-pair#3</name>
<arg>item()*</arg>
<arg>item()*</arg>
<arg>
<expected>function(item(), item()) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="fn_for-each_2">
<name>for-each#2</name>
<arg>item()*</arg>
<arg>
<expected>function(item()) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="fn_format-dateTime_2">
<name>format-dateTime#2</name>
<arg>xs:dateTime?</arg>
<arg>xs:string</arg>
<return>
<expected>xs:string?</expected>
<actual>xs:string</actual>
</return>
</testcase>
<testcase name="fn_format-dateTime_5">
<name>format-dateTime#5</name>
<arg>xs:dateTime?</arg>
<arg>xs:string</arg>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<return>
<expected>xs:string?</expected>
<actual>xs:string</actual>
</return>
</testcase>
<testcase name="fn_format-date_2">
<name>format-date#2</name>
<arg>xs:date?</arg>
<arg>xs:string</arg>
<return>
<expected>xs:string?</expected>
<actual>xs:string</actual>
</return>
</testcase>
<testcase name="fn_format-date_5">
<name>format-date#5</name>
<arg>xs:date?</arg>
<arg>xs:string</arg>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<return>
<expected>xs:string?</expected>
<actual>xs:string</actual>
</return>
</testcase>
<testcase name="fn_format-number_3">
<name>format-number#3</name>
<arg>xs:numeric?</arg>
<arg>xs:string</arg>
<arg>
<expected>xs:string?</expected>
<actual>xs:string</actual>
</arg>
<return>xs:string</return>
</testcase>
<testcase name="fn_format-time_2">
<name>format-time#2</name>
<arg>xs:time?</arg>
<arg>xs:string</arg>
<return>
<expected>xs:string?</expected>
<actual>xs:string</actual>
</return>
</testcase>
<testcase name="fn_format-time_5">
<name>format-time#5</name>
<arg>xs:time?</arg>
<arg>xs:string</arg>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<return>
<expected>xs:string?</expected>
<actual>xs:string</actual>
</return>
</testcase>
<testcase name="fn_hours-from-duration_1">
<name>hours-from-duration#1</name>
<arg>
<expected>xs:duration?</expected>
<actual>xs:dayTimeDuration?</actual>
</arg>
<return>xs:integer?</return>
</testcase>
<testcase name="fn_index-of_2">
<name>index-of#2</name>
<arg>xs:anyAtomicType*</arg>
<arg>xs:anyAtomicType</arg>
<return>
<expected>xs:integer*</expected>
<actual>xs:integer?</actual>
</return>
</testcase>
<testcase name="fn_index-of_3">
<name>index-of#3</name>
<arg>xs:anyAtomicType*</arg>
<arg>xs:anyAtomicType</arg>
<arg>xs:string</arg>
<return>
<expected>xs:integer*</expected>
<actual>xs:integer?</actual>
</return>
</testcase>
<testcase name="fn_last_0">
<name>last#0</name>
<return>
<expected>xs:integer</expected>
<actual>xs:integer?</actual>
</return>
</testcase>
<testcase name="fn_matches_2">
<name>matches#2</name>
<arg>
<expected>xs:string?</expected>
<actual>xs:string*</actual>
</arg>
<arg>xs:string</arg>
<return>xs:boolean</return>
</testcase>
<testcase name="fn_matches_3">
<name>matches#3</name>
<arg>
<expected>xs:string?</expected>
<actual>xs:string*</actual>
</arg>
<arg>xs:string</arg>
<arg>xs:string</arg>
<return>xs:boolean</return>
</testcase>
<testcase name="fn_minutes-from-duration_1">
<name>minutes-from-duration#1</name>
<arg>
<expected>xs:duration?</expected>
<actual>xs:dayTimeDuration?</actual>
</arg>
<return>xs:integer?</return>
</testcase>
<testcase name="fn_months-from-duration_1">
<name>months-from-duration#1</name>
<arg>
<expected>xs:duration?</expected>
<actual>xs:yearMonthDuration?</actual>
</arg>
<return>xs:integer?</return>
</testcase>
<testcase name="fn_name_0">
<name>name#0</name>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_name_1">
<name>name#1</name>
<arg>node()?</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_parse-xml-fragment_1">
<name>parse-xml-fragment#1</name>
<arg>xs:string?</arg>
<return>
<expected>document-node()?</expected>
<actual>element()*</actual>
</return>
</testcase>
<testcase name="fn_parse-xml_1">
<name>parse-xml#1</name>
<arg>xs:string?</arg>
<return>
<expected>document-node(element(*))?</expected>
<actual>document-node()?</actual>
</return>
</testcase>
<testcase name="fn_position_0">
<name>position#0</name>
<return>
<expected>xs:integer</expected>
<actual>xs:integer?</actual>
</return>
</testcase>
<testcase name="fn_replace_3">
<name>replace#3</name>
<arg>xs:string?</arg>
<arg>xs:string</arg>
<arg>xs:string</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_replace_4">
<name>replace#4</name>
<arg>xs:string?</arg>
<arg>xs:string</arg>
<arg>xs:string</arg>
<arg>xs:string</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_resolve-QName_2">
<name>resolve-QName#2</name>
<arg>xs:string?</arg>
<arg>element()</arg>
<return>
<expected>xs:QName?</expected>
<actual>xs:QName</actual>
</return>
</testcase>
<testcase name="fn_round-half-to-even_1">
<name>round-half-to-even#1</name>
<arg>xs:numeric?</arg>
<return>
<expected>xs:numeric?</expected>
<actual>xs:numeric</actual>
</return>
</testcase>
<testcase name="fn_round-half-to-even_2">
<name>round-half-to-even#2</name>
<arg>xs:numeric?</arg>
<arg>
<expected>xs:integer</expected>
<actual>xs:numeric?</actual>
</arg>
<return>
<expected>xs:numeric?</expected>
<actual>xs:numeric</actual>
</return>
</testcase>
<testcase name="fn_round_1">
<name>round#1</name>
<arg>xs:numeric?</arg>
<return>
<expected>xs:numeric?</expected>
<actual>xs:numeric</actual>
</return>
</testcase>
<testcase name="fn_seconds-from-duration_1">
<name>seconds-from-duration#1</name>
<arg>
<expected>xs:duration?</expected>
<actual>xs:dayTimeDuration?</actual>
</arg>
<return>xs:decimal?</return>
</testcase>
<testcase name="fn_sort_3">
<name>sort#3</name>
<arg>item()*</arg>
<arg>xs:string?</arg>
<arg>
<expected>function(item()) as xs:anyAtomicType*</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="fn_starts-with_2">
<name>starts-with#2</name>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<return>
<expected>xs:boolean</expected>
<actual>xs:boolean?</actual>
</return>
</testcase>
<testcase name="fn_starts-with_3">
<name>starts-with#3</name>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<arg>xs:string</arg>
<return>
<expected>xs:boolean</expected>
<actual>xs:boolean?</actual>
</return>
</testcase>
<testcase name="fn_string-join_1">
<name>string-join#1</name>
<arg>
<expected>xs:anyAtomicType*</expected>
<actual>xs:string*</actual>
</arg>
<return>xs:string</return>
</testcase>
<testcase name="fn_string-join_2">
<name>string-join#2</name>
<arg>
<expected>xs:anyAtomicType*</expected>
<actual>xs:string*</actual>
</arg>
<arg>xs:string</arg>
<return>xs:string</return>
</testcase>
<testcase name="fn_string-length_0">
<name>string-length#0</name>
<return>
<expected>xs:integer</expected>
<actual>xs:integer?</actual>
</return>
</testcase>
<testcase name="fn_string-length_1">
<name>string-length#1</name>
<arg>xs:string?</arg>
<return>
<expected>xs:integer</expected>
<actual>xs:integer?</actual>
</return>
</testcase>
<testcase name="fn_substring-after_2">
<name>substring-after#2</name>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_substring-after_3">
<name>substring-after#3</name>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<arg>xs:string</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_substring-before_2">
<name>substring-before#2</name>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_substring-before_3">
<name>substring-before#3</name>
<arg>xs:string?</arg>
<arg>xs:string?</arg>
<arg>xs:string</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_substring_2">
<name>substring#2</name>
<arg>xs:string?</arg>
<arg>xs:double</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_substring_3">
<name>substring#3</name>
<arg>xs:string?</arg>
<arg>xs:double</arg>
<arg>xs:double</arg>
<return>
<expected>xs:string</expected>
<actual>xs:string?</actual>
</return>
</testcase>
<testcase name="fn_sum_2">
<name>sum#2</name>
<arg>xs:anyAtomicType*</arg>
<arg>xs:anyAtomicType?</arg>
<return>
<expected>xs:anyAtomicType?</expected>
<actual>xs:anyAtomicType</actual>
</return>
</testcase>
<testcase name="fn_years-from-duration_1">
<name>years-from-duration#1</name>
<arg>
<expected>xs:duration?</expected>
<actual>xs:yearMonthDuration?</actual>
</arg>
<return>xs:integer?</return>
</testcase>
<testcase name="map_for-each_2">
<name>map:for-each#2</name>
<arg>map(*)</arg>
<arg>
<expected>function(xs:anyAtomicType, item()*) as item()*</expected>
<actual>function(*)</actual>
</arg>
<return>item()*</return>
</testcase>
<testcase name="map_remove_2">
<name>map:remove#2</name>
<arg>map(*)</arg>
<arg>
<expected>xs:anyAtomicType*</expected>
<actual>xs:string</actual>
</arg>
<return>map(*)</return>
</testcase>
<testcase name="math_acos_1">
<name>math:acos#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_asin_1">
<name>math:asin#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_atan_1">
<name>math:atan#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_cos_1">
<name>math:cos#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_exp10_1">
<name>math:exp10#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_exp_1">
<name>math:exp#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_log10_1">
<name>math:log10#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_log_1">
<name>math:log#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_pow_2">
<name>math:pow#2</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<arg>xs:numeric</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_sin_1">
<name>math:sin#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_sqrt_1">
<name>math:sqrt#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
<testcase name="math_tan_1">
<name>math:tan#1</name>
<arg>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</arg>
<return>
<expected>xs:double?</expected>
<actual>xs:double</actual>
</return>
</testcase>
</signature-mismatches>
xquery version "3.1";
element signature-mismatches {
let $testcases := doc("/db/results.xml")//testcase
for $case in $testcases[failure]
let $expected := parse-xml($case/failure)/signature/*
let $actual := $case/output/signature/*
let $analysis :=
for-each-pair(
$expected,
$actual,
function($e, $a) {
if (deep-equal($e, $a)) then
$e
else
element { name($e) } {
element expected { $e/string() },
element actual { $a/string() }
}
}
)
return
element testcase { $case/@name, $analysis }
}
A query to read the results of https://gist.github.com/joewiz/4ce1a564553d954855fe7500989afe22 and generate a report about function signature mismatches between the W3C XPath & XQuery Functions & Operators spec and eXist's implementation.
以上是关于markdown 一份报告显示了eXist实现XPath&XQuery函数和运算符规范中的函数签名不匹配的主要内容,如果未能解决你的问题,请参考以下文章
如何在python中用markdown语言写一份报告并输出成PDF格式
Rstudio怎么生成html文件 Rstudio生成html报告方法介绍
IF EXIST C:\directory\ goto a else goto b 问题 windows XP 批处理文件
markdown Oracle Drop If Exists.md