Ticket #77 (closed defect: fixed)

Opened 2 years ago

Last modified 2 years ago

test_auto_string_value returning a value when it shouldn't

Reported by: kkalmbach Owned by: ser
Priority: normal Milestone: 3.1.7
Component: XPath Version: 3.1.3
Severity: normal Keywords:
Cc: Ruby version: 1.8.2
Operating system: Windows

Description

in the unit test_auto_string_value (in xpath_test.rb), I think there is a problem....

If I change this unit test slightly to add this test (I added it to line 676 in my case)..

  r = REXML::XPath.match( d, %q{a[c='xtest']} )
  assert_equal( 0, r.size )

The xml has no node with c who's value is xtest, so the result should be 0, but I still get a size of 1 (The root node is still returned)

Here is beginning of my bin/suite.rb output..

C:\ruby\rails\rexml_3.1.4>ruby bin/suite.rb
["3.1.4", "1.8.4", "2006-04-14"]
REXML version = 3.1.4
Loaded suite REXML
Started

Change History

Changed 2 years ago by ser

  • milestone changed from 3.1.6 to 3.1.7

Changed 2 years ago by ser

  • status changed from new to closed
  • resolution set to fixed

This was probably fixed in a previous version. The issue does not appear in 3.1.6. A test has been added to confirm that this is working correctly, committed in changeset:1242.

Note: See TracTickets for help on using tickets.