Fix and Re-enable some unit tests on dialog, tooltip, and draggable #1144
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While working on one of my own modules that extends dialogs, I wanted to validate existing dialog tests passed and realized they were disabled in grunt/phantomjs out of the box.
When looking deeper, it seems the main reason my have been the tiny viewportSize phantomjs starts out with causing some of the issues. A PR to gruntjs/grunt-lib-phantomjs#21 adds the ability to change the viewport directly from the config. I know the tests won't pass in your CI until this is fixed, but I wanted to record this PR just so I didn't forget about them. Alternatively, I could have included alternate phantomjs/main.js and a phantomScript option, but that didn't seem like the best option.
Note, I do have questions about the fixes I did here (bdowling/jquery-ui@jquery:master...master#diff-1b4b30b16776f6b3f0a4f05ddfbeb518R561).. Not sure why
$(":focus")
differs fromdocument.activeElement
in these instances in phantomjs, but I don't think changing this impacts what is being tested here. Perhaps a separate test that should be included in jQuery itself?