Mink
Mink copied to clipboard
fieldset named selector returns the most outer fieldset instead of the closest ancestor
In an attempt to use the fieldset named selector, it did not return the fieldset I expected it to return when using find() with the legend value as a locator and fieldsets are nested. Instead of the closest ancestor fieldset a legend belongs to, it returns the farthest ancestor fieldset. An example:
- fieldset 1
- fieldset 1.1
- legend "a"
- fieldset 1.2
- legend "b"
- fieldset 1.1
When using the fieldset named selector with the value of either legend "a" or legend "b", in both cases fieldset 1 is returned, while I expected it to return respectively fieldset 1.1 and fieldset 1.2
It would be better demonstrated with a failing test case sent as PR or at least HTML and PHP code posted in here to demonstrate the problem.
@aik099 sure, I'll provide a test.
Should be closed in favour of #726.