This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 20102 - [XT3TS] backwards-039
Summary: [XT3TS] backwards-039
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XSLT 3.0 Test Suite (show other bugs)
Version: Working drafts
Hardware: PC Windows NT
: P2 normal
Target Milestone: ---
Assignee: Abel Braaksma
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-27 17:19 UTC by Tim Mills
Modified: 2012-11-28 06:59 UTC (History)
1 user (show)

See Also:


Attachments

Description Tim Mills 2012-11-27 17:19:48 UTC
Are the expected results for this test correct?

The keys are:

 <xsl:key name="k" match="item" use="."/> (from XSLT 1.0 stylesheet)
 <xsl:key name="k" match="item" use="number(.)"/> (from XSLT 2.0 stylesheet)

The input number is:

<content>
 <data>
  <item>1.00</item>
  <item>2.00</item> 
  <item>1</item>  
  <item>2</item> 
 </data>
</content>

Both will use backwards-compatbility behaviour, due to one key being from an XSLT 1.0 stylesheet.

key('k', 1.0) will return:

 <item>1.00</item> because number(<item>1.00</item>) cast as string = 
                           number(1.0) cast as string

and

  <item>1</item>  because number(<item>1</item>) cast as string = 
                           number(1.0) cast as string

Have I missed something?
Comment 1 Michael Kay 2012-11-28 00:08:07 UTC
Saxon is failing this test too, so I suspect you are right that something is wrong with the test.
Comment 2 Michael Kay 2012-11-28 00:45:25 UTC
I agree with your analysis and will change the expected result accordingly.

I'm puzzled by the history. The test appeared in the old test suite as backwards026a and the new test seems identical to the old; Saxon was reporting success against the old test, yet when I run it freestanding it doesn't report the expected results. The old test suite used the same results file for both tests backwards026 and backwards026a and this could have somehow confused my test driver. Anyway, investigating history is rarely productive in such matters, so I shall just fix it.
Comment 3 Tim Mills 2012-11-28 06:59:28 UTC
We were also passing the test in the old test suite.

Confirmed fixed - thanks.