https://jsfiddle.net/bnwrhaan/1/
There are two broken tests:
- DoesNotContainOtherProperties
- equalTo
I can get DoesNotContainOtherProperties working with:
There's a spot in the code:
- $.validator
- .addMethod(
- "doesnotcontainotherproperties",
- function(v, e, o) {
- var ok = true;
- var $form = $(e).closest("form");
- $(o)
- .each(
- function() {
- var propertyValue = $(
- ':input[name=' + this
- + ']', $form)
- .val();
- if (propertyValue.length) {
- if (propertyValue
- .search(",")) {
- propertyValue = propertyValue
- .split(",");
- }
Where if I change from:
- var propertyValue = $(
- ':input[name=' + this
- + ']', $form)
- .val();
To:
- var propertyValue = $(
- ':input[name=\"' + this + '\"]')
- .val();
..then it seems to work. I have no idea what side effects I'm introducing, though. I think it should probably be localized to the $form that was found, but I'm just guessing here.
The failing equalTo test is even harder to debug.