Stef Heyenrath
Stef Heyenrath
@Todo18 Can you provide a unit-test for this?
@Todo18 I copied your code and created 2 unit tests: - https://github.com/StefH/XPath2.Net/blob/stef-issue-59/tests/XPath2.Tests/XPathNavigatorTests.cs#L366 - https://github.com/StefH/XPath2.Net/blob/stef-issue-59/tests/XPath2.Tests/XPathNavigatorTests.cs#L391 And these run fine? Can you double check what's the difference?
@Todo18 Can you please take a look at the unit tests and check the difference with your code?
@Todo18 Did you have time to check?
Please note that my unit tests are the same as your unit test. Please look at * https://github.com/StefH/XPath2.Net/blob/stef-issue-59/tests/XPath2.Tests/XPathNavigatorTests.cs#L366 * https://github.com/StefH/XPath2.Net/blob/stef-issue-59/tests/XPath2.Tests/XPathNavigatorTests.cs#L391
According to the documentation: https://learn.microsoft.com/en-us/dotnet/api/system.xml.xpath.xpathnodeiterator.count?view=net-7.0 **Count** => _Gets the index of the last node in the selected set of nodes._ So it's not the number of nodes, it's the index,...
But `CurrentPosition` is not the same as `Count`.
Just an observation: https://codebeautify.org/Xpath-Tester  
Also note that the original XPath does also not work: ``` c# [Fact] public void XPath2SelectNodesWithDefaultNamespace() { var namespaceManager = new XmlNamespaceManager(new NameTable()); namespaceManager.AddNamespace(string.Empty, "http://www.w3.org/1999/xhtml"); var nodeListXPath1 = GetXHTMLSampleDoc().SelectNodes("//p", namespaceManager);...
I don't know exactly the difference between v1 en v2 in regard to this specific query, So I assumed that this `SelectNodes` method should just behave the same. If that...