We need some tests that:
- Inserts an image via the WYSIWYG editor, setting it's Alt and Title text
- Edits the image again (selecting it and clicking the Media button) and verifies the Alt and Title are as they should be
- It should include characters that are frequently encoded (like & and < or >), and make sure they get decoded properly
- Checks that changes "stick" when ultimately viewing the image outside of the WYSIWYG
This will help to verify that issues like these won't recur:
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | panopoly_test-alt-title-2308325-8.patch | 3.89 KB | dsnopek |
| #4 | panopoly_test-alt-title-2308325-4.patch | 7.54 KB | dsnopek |
Comments
Comment #1
dsnopekHere is my first sort of maybe working attempt. Posting here so I can try in Travis-CI!
Comment #2
dsnopekHere is an alternate patch that tries to use the Mink API rather than Javascript. I don't actually expect it to work, but I'd really like to try it on Travis-CI just in case, because it would be cleaner approach.
Comment #3
dsnopekHere's another "real" patch for this - hopefully it'll fix the couple of failures on Travis.
Comment #4
dsnopekThe previous patch worked:
https://travis-ci.org/dsnopek/panopoly/builds/30780536
Here is one last patch for Travis-CI. This one remove the code related to the failed attempt at using the Mink API. If that passes, this is ready to be committed.
Comment #6
dsnopekAlright, it passed! Committed. :-) Let's see what the final word from Travis is:
https://travis-ci.org/panopoly/panopoly/builds/30784912
Comment #7
dsnopekThere were a few extra characters we failed to check, namely: apostrophes and quotes. Since these were at one point broken and now appear to be working, I'd like it to stay that way! Here is a patch that I'm going to test on Travis, since I'm having trouble running it locally.
Comment #8
dsnopekDidn't get the quote escaping quite right - here's another attempt. (It's sort of ironic that I'm dealing with quote escaping issues in the Behat test file, while trying to test for quote escaping issues in Panopoly. ;-))
Comment #10
dsnopekOk, it's now checking quotes too! I already tested with Travis while working on the patch, but here is the final build of what was committed:
https://travis-ci.org/panopoly/panopoly/builds/31178687