I guess the left-hand side report looks like this:
> Result
> XPath /*/@* from:
> <pseudo-attribute ... />
and the right-hand side report looks like this:
> Expected Result
> XPath /text() from:
> finding2
Note "/*/@*" and "/text()" in "XPath ... from". So, the actual result of
your stylesheet (filtered by x:expect/@test) was an attribute node while
you expected a text node.
(<psuedo-attribute> is a pseudo representation of an attribute. See
"<pseudo-*>" in
https://github.com/xspec/xspec/wiki/Understanding-Test-Results#pseudo- )
An attribute node and a text node are different node types even if their
values are the same. That's why the test is Failure.
If you write <x:expect> as follows, the test will be Success because
this time both the actual result and the expected result are strings:
<x:expect
test=".../@internal-destination/string()"
select="'finding2'" />
or
<x:expect
test=".../@internal-destination/string()"
select="string()">finding2</x:expect>
Another option would be to expect an attribute node:
<x:expect
test=".../@internal-destination"
select="e/@*">
<e internal-destination="finding2" />
</x:expect>
A similar case is discussed in "Difference in XPath ... from" in
https://github.com/xspec/xspec/wiki/Understanding-Test-Results#difference-in-xpath--from
.
--
AirQuick
> --
> You received this message because you are subscribed to the Google
> Groups "XSpec" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to
xspec-users...@googlegroups.com.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/xspec-users/75ed1ab7-215e-4642-8ee8-383876051e12n%40googlegroups.com.