GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
This is a possible fix for #1663.
When cloning a node, removing the name attribute from any inputs of type radio inside the dragged node, will prevent them from unchecking the selected radio button on its group.
I've added a test to verify this. Somehow it works properly when launched with yeti, but fails to pass when launched via yogi. Am I missing something here?
I've also created a demo with the working fix
Add test for dd-proxy with cloneNode and radio inputs
Remove name attribute radio inputs inside cloned nodes by dd-proxy
This is the yeti report when running the dd tests:
Agent connected: Internet Explorer (8.0) / Windows XP 64 from XXX.XX.XX.XX
Agent connected: Firefox (27.0) / Windows XP 64 from XXX.XX.XX.XX
Agent connected: Chrome (23.0.1271.97) / Windows XP 64 from XXX.XX.XX.XX
✓ Testing started on Internet Explorer (8.0) / Windows XP 64, Firefox (27.0) / Windows XP 64, Chrome (23.0.1271.97) / Windows XP 64
✓ Agent completed: Chrome (23.0.1271.97) / Windows XP 64
✓ Agent completed: Firefox (27.0) / Windows XP 64
✓ Agent completed: Internet Explorer (8.0) / Windows XP 64
✓ 144 tests passed! (48 seconds)
No takers? 😢
Sorry for being late. I confirmed that passed tests with IE6, IE7, IE9, IE10, IE11 and Safari, but it seems to fails tests with PhantomJS as Travis CI shows.
[okuryu.local](yui3@DD-Proxy-reset-radio)$ grover tests/unit/index.html
Starting Grover on 1 files with PhantomJS@1.9.7
Running 15 concurrent tests at a time.
✖ [DragDrop]: Passed: 47 Failed: 1 Total: 48 (ignored 0) (4.204 seconds)
test: proxy cloneNode with radio inputs
Value should be true.
Expected: true (boolean)
Actual: false (boolean)
✖ [Total]: Passed: 47 Failed: 1 Total: 48 (ignored 0) (4.204 seconds)
[Grover Execution Timer] 5.165 seconds
Hey @okuryu, no problem!
I'm a bit puzzled about the test failing on PhantomJS... do you have any idea as to how to approach/fix this? Could we skip this given test for PhantomJS?
hmm, I have looked but it's weird. How about putting ignore conditional with Y.UA.phantomjs?
Maybe I think that </input> is unnecessary.
I tried, but made no difference. Test still fails in PhantomJS 😢
Ignore test in PhantomJS
CLA is valid!
@okuryu I've pushed a commit ignoring the test in PhantomJS. Not sure if this has triggered a new CI build, though...
@jbalsas Thanks. Looks good to me. I'll merge this when get +1 from a reviewer or after 72 hours (excludes holidays).
Awesome @okuryu, thanks a lot!
Merged. I believe this will be available in the next release.
@okuryu Thanks so much for helping out and seeing this through!