Commit graph

225 commits

Author SHA1 Message Date
Amir E. Aharoni 5a715d05ad [BrowserTest] Remove an empty line to make Rubocop pass
Change-Id: I110fef0f98ee7a2c5b74971b1e068bca0869e912
2015-02-17 10:20:12 +00:00
Amir E. Aharoni c37fe8fe5e [BrowserTest] Move screenshot taking functionality to a gem
* Screenshot taking logic and rspec tests are deleted from this repo
  and moved to
  https://rubygems.org/gems/screenshot
* Dependency on chunky_png is removed from VisualEditor
  (and added to the screenshot gem).
* The method calls are renamed accordingly.

Change-Id: I6a0e2cc770a07f36f63bc536db109b63d38a4fd2
2015-02-17 09:57:44 +00:00
Roan Kattouw 9a4c192c44 Update VE core submodule to master (f86c97c)
New changes:
e325520 Create APIResultsProvider and APIResultsQueue and add tests
4ead645 Make newFromAnnotation test construct doc2 from data, not HTML
804fb17 Remove useless getDataElementFromDomElement / getDomElementsFromDataElement tests
c2fc6a0 DomFromModelTest: Call modify() on the document, not the data
1535331 Inline ve.ce.View#renderAttributes

Local changes:
Update modify callbacks to work on document instead of data.

Change-Id: Ia875d11627adc38f78dd5010f9ab03e8b083b448
2015-02-16 11:44:34 -08:00
Ed Sanders ec4acecf33 Correctly tag clipboard DM from MWTransclusionNodes
Iff in clipboard mode:
* Set data-ve-no-generated-contents on the main element
  regardless of whether we are using orignal DOM elements.
* Set data-ve-ignore on siblings, again, regardless or
  where they came from.

Bug: T89658
Change-Id: I82ad60f0b90e0c6ce88c42737bd36d1a289bcf34
2015-02-16 16:52:04 +00:00
Roan Kattouw 3528aeb8d3 Rename test modules to stop confusing QUnit
Some modules had the same name as test modules in VE core,
and this broke expand/collapse behavior in QUnit.

Change-Id: I7fd0b454b3377b7c289ddebbf91146fcbe5945c4
2015-02-13 16:12:03 -08:00
Cmcmahon df1013b7da [BrowserTest] Remove unused steps and locators
No more iframes

Change-Id: I3d6420f2a017a132d5695921daa5efb5117f3176
2015-02-12 11:53:58 -07:00
Cmcmahon 5d03721bb7 [BrowserTest] Update transclusion test for better locator
Also remove unused step and element

Change-Id: If99cde6a3ec1f0fb87628e5d8600a83034e11ee1
2015-02-12 11:27:40 -07:00
Cmcmahon 7d3e8a8ac5 [BrowserTest] Cite message no longer in iframe
Change-Id: I027bf87c0eb91edb7dc6218c3bc8f66a8c1aa69e
2015-02-12 10:54:02 -07:00
jenkins-bot 57bffa14c6 Merge "Support specifying reference contents with data-mw.body.id" 2015-02-11 20:18:11 +00:00
Cmcmahon 924e738652 [BrowserTest] Bring references test up to date.
This addresses some old technical debt.

We also shifted the re-use reference test to the cite.feature where
it belongs in the current architecture.

Paired with Rummana for the update

Change-Id: Ie50ac5bffec0d0ab6bcad704c323639f8e8553f0
2015-02-10 15:57:44 -07:00
jenkins-bot 31e4fbec90 Merge "[BrowserTest] Update the definition of formula_image element" 2015-02-10 09:41:30 +00:00
ryasmeen@wikimedia.org 0245af2047 [BrowserTest] Fix only Media Test
The media test was passing against garbage wikitext markup match.
Fixed the steps so that it fails when it should.

Change-Id: I3d8dbc959c6244968dd9ac58af663b81cb115dc6
2015-02-09 15:41:42 -08:00
Roan Kattouw 26e5a885bc Support specifying reference contents with data-mw.body.id
If data-mw.body.html is not set, search for the element
whose ID matches data-mw.body.id and use its contents.

.body.html is still used for new content: new references
use .body.html, and if a reference using .body.id is
changed, the changed HTML is output in .body.html.

Bug: T88650
Change-Id: I5d614927256d59a3ab20b0bd6e882b5cb8fcda20
2015-02-09 20:54:50 +00:00
Roan Kattouw 396eb606a6 Update VE core submodule to master (83a526a)
New changes:
23a9e11 Localisation updates from https://translatewiki.net.
9f1350f Update UnicodeJS to v0.1.3
f869803 Localisation updates from https://translatewiki.net.
ce11fb3 Use css class rather than jQuery show/hide
0d4584c Fix definition of ve.Range#containsRange
8a5c7d9 Fix rangeInsideOneLeafNode
8ce5f60 Localisation updates from https://translatewiki.net.
d2104aa Track originalHtml in internalItems
9823624 Localisation updates from https://translatewiki.net.

Local changes:
Update tests for internalItem originalHtml change

Bug: T88650
Change-Id: Ie7532cade7e3006e1bf39c12c97962da415ab993
2015-02-09 11:29:43 -08:00
Cmcmahon 3db521ce41 [BrowserTest] make References test pass
Somehow the Insert element got removed from the page object. Fixeded.

Change-Id: I970d4824ebeed817f621b09714e0d58d99bee573
2015-02-09 10:36:44 -07:00
Cmcmahon 18679b74ba [BrowserTest] Make media tests pass
Like in the Cite tests, need a sleep to make the tests pass
locally.

Updated a locator also

Change-Id: Idd962e110fd7191325bdac7e641960858de1db9e
2015-02-09 10:24:12 -07:00
Cmcmahon dd671b4843 [BrowserTest] update Cite test to pass
I'm hoping the sleep() calls here are temporary. VE seems to be
loading an intermediate page before showing the diff view, or
sending an invalid onload event or some such.

Also updated the locator for the Basic text input

Change-Id: I73795f6b1ff0da42f8afd92598ab6786c9a0b88b
2015-02-09 10:00:41 -07:00
ryasmeen@wikimedia.org cefb9b265a [BrowserTest] [WIP]Fixing the test media_general_settings.feature
Change-Id: Ic83477f12db08ed25452f19ca3dc410940a8ebf5
2015-02-06 16:16:33 -07:00
Amir E. Aharoni 8d5b48d018 [BrowserTest] Update the definition of formula_image element
The class name of the formula image changed.

Follow up to
Ib50d0381f5743db1f6678609cd4eca5a56a8682b

Change-Id: Ic78b5be572c8757c4d8f35bd878adf4ecf7c8fb0
2015-02-05 14:26:59 +02:00
Amir E. Aharoni 2e0b191dda [BrowserTest] Refactor offset_element and browser_zoom
offset_element was used for iframes, and now there are no iframes,
so there is no reason to use it.

As for browser_zoom, it makes more sense to do it in a separate function
and not as a parameter to capture_screenshot.

Change-Id: Ibfce33b7a56d883cc1a6c92c19d40c499681fa47
2015-02-05 12:40:28 +02:00
Amir E. Aharoni 4a73b3e4b1 [BrowserTest] Rename iframe to window_frame
It's not an iframe anymore, so the name shouldn't be confusing.

Change-Id: Id93595d56d7d88871ab79ca91e1714d9a70fad17
2015-02-05 10:32:21 +00:00
Amir E. Aharoni 4bab4fd921 [BrowserTest] Restore the formula screenshot scenario
* Restore the Formula editor screenshot scenario, which was disabled in
  I3e892baa9cb2c8c1303fab232a2b1c64ebdd8f26
* Get the 'More' element clicked to show the formula item.
* Fix the definition of the formula editor textarea element.

Change-Id: Ib50d0381f5743db1f6678609cd4eca5a56a8682b
2015-02-05 10:28:37 +00:00
Amir E. Aharoni 8063c6c754 [BrowserTest] Restore page settings language screenshots
* Add classes to elements in the page settings dialog boxes
* Restore the scenario that was disabled in
Id41d1329d22679b6a61201ceafc81eafa222d909

Change-Id: I5636e744daec2adf013d399bfb019e4d47912083
2015-02-05 12:16:48 +02:00
Amir E. Aharoni ae4417e60d [BrowserTest] Click the editable area with .when_present
The editable area sometimes didn't appear, so a .when_present
call is added to check that it's on the screen.

Bug: T88663
Change-Id: I0c5e29a9d7f9d0a22ca8392df9f7a5b857f20d7d
2015-02-05 12:13:15 +02:00
jenkins-bot 130edbfe62 Merge "[BrowserTest] Shorten all capture_screenshot lines" 2015-02-05 09:19:23 +00:00
jenkins-bot 3351d84bf0 Merge "[BrowserTest] Restore the indentation list screenshot scenario" 2015-02-05 09:17:55 +00:00
jenkins-bot c73d949ba7 Merge "[BrowserTest] Show the complete insert pull-down in screenshots" 2015-02-05 09:15:07 +00:00
jenkins-bot 8238658ad7 Merge "[BrowserTest] Consistent names for variables that refer to down-arrow" 2015-02-05 09:12:25 +00:00
jenkins-bot 04f398beaa Merge "[BrowserTest] Shorten lines for clarity" 2015-02-05 09:10:53 +00:00
jenkins-bot 8900b2ce92 Merge "[BrowserTest] Simplify the Selenium selector for the Save button" 2015-02-05 09:05:36 +00:00
jenkins-bot b5ea06c276 Merge "Improve references test data" 2015-02-04 01:16:19 +00:00
Roan Kattouw bc51095888 Improve references test data
* Remove unused extsrc
* Add <a>s inside of reference <span>s
* Add <li>s inside of reference list
* Change reference list to one for the g1 group rather than the main group
* Consequently, the reference defined inside the reference list moves to g1
** Due to a bug, explicitly set group="g1" on that ref for now

Change-Id: I266a4323c7353e00bd4288d5de51c252bbcdf3d7
2015-02-03 16:43:15 -08:00
ryasmeen@wikimedia.org fcb9473c68 [BrowserTest] Test for checking General Settings for media
Change-Id: I503c01642a9fc23684912909e8da8e61998528a6
2015-02-03 21:53:40 +00:00
jenkins-bot 07e95ac365 Merge "[BrowserTest] Updating test for Media Settings interface" 2015-02-03 07:42:33 +00:00
jenkins-bot 2388ee443c Merge "build: Bump devDependencies to latest" 2015-02-02 22:43:21 +00:00
James D. Forrester bed038b509 build: Bump devDependencies to latest
Updates:
* grunt-contrib-csslint  0.3.1  ->  0.4.0
* grunt-contrib-jslint   0.10.0 -> 0.11.0
* grunt-jscs             0.8.1  ->  1.2.0

For jscs, leaving requireSpacesInsideArrayBrackets to avoid headaches for now.

Change-Id: I62d34444edbba65c8bd22d2fa5e50e16cabb0042
2015-02-02 14:30:39 -08:00
Elena Tonkovidova 0240a51717 [BrowserTest] Add basic test for table creation
Change-Id: I07022e27da9d7114c18a82cdbd62e4cb82ddc7e2
2015-02-02 15:15:13 -07:00
Roan Kattouw 2bdb20b3c1 Don't corrupt href="./" in internal links
href="./" was being corrupted to href=""

Change-Id: Ieedd71a991c6b52225f2ac41ebe1a20e7533c19e
2015-01-30 18:44:57 -08:00
ryasmeen@wikimedia.org eea130381a [BrowserTest] Updating test for Media Settings interface
Fixed the following:
1.The workflow was incomplete and incorporated new changes
2.Wrong css pointer to the first image
3.The Given statement was defined as When in step definition file
4.Removed unnecessary/obsolete steps that was making the test to fail while we can verify the basic functionality with miminum steps.

Change-Id: Ic8a265678900ed52bbed6d90e971d6c016ef610d
2015-01-30 18:11:33 -08:00
Cmcmahon ee79759d5f [BrowserTest] remove old hack and fix "a is undefined" bug
This patch removes an old hack from the early days of VE.

Coincidentally, this hack is the root cause of the bug reported
by me, Erik Berhardson, and Elena Tonkovidova: T87446

Thanks Elena for finding this!

Bug: T87446
Change-Id: I325f60586373427acc2cd8f6e2e7d7accac80695
2015-01-30 22:56:15 +00:00
Cmcmahon fca9110172 [BrowserTest] make rubocop stop complaining
extra lines in the language_screenshot unit test file

Change-Id: I898ad4c1ce5537c02574dd340866260c18d14cee
2015-01-30 14:07:17 -07:00
Amir E. Aharoni f4d10e3ee6 [BrowserTest] Shorten all capture_screenshot lines
Change-Id: I01c11dfc4f4706d45e7bc62261ed133a7bd72092
2015-01-27 21:37:09 +00:00
Amir E. Aharoni 8da4c9b3cc [BrowserTest] Restore the indentation list screenshot scenario
* Add a class to the indentation toolbar button, similarly to what was done in
  Ib0cb67151d893a5d2efccf798d6b25d197ed34d2
* Fix the definition of the indentation pull-down element acordingly.
* Restore the Indentation menu screenshot scenario, which was disabled in
  I3e892baa9cb2c8c1303fab232a2b1c64ebdd8f26

Change-Id: If2d92aab6d04aa487d6f753fa7cac94f8d8215c8
2015-01-27 13:35:39 -08:00
Amir E. Aharoni d20d70cdd6 [BrowserTest] Show the complete insert pull-down in screenshots
The "insert_pull_down" element only included the menu trigger.

Now it includes the complete pull-down with all the items.

This is consistent with other pull-down elements.

Change-Id: I3f6052eab1ee0322ebb7e6f2116e2d5d0e25f5b1
2015-01-27 13:35:39 -08:00
Amir E. Aharoni 3f31715c09 [BrowserTest] Consistent names for variables that refer to down-arrow
Change-Id: Ib7c799af449a9427f6ba25403cbd6b2d220133f0
2015-01-27 13:35:39 -08:00
Amir E. Aharoni 39afc66a91 [BrowserTest] Shorten lines for clarity
The 'I take screenshot of insert pull-down menu' step has many
similar very long lines. Shortening them makes
the code more understandable and conforming to the conventions.

Change-Id: I83b35211a6cbfdc420895469747884f3ae864479
2015-01-27 13:35:39 -08:00
Amir E. Aharoni 024481baae [BrowserTest] Simplify the Selenium selector for the Save button
The selector was very long and incorrect.

This patch simplifies and corrects the selector.

This also fixes the VisualEditor_save_dialog scenario
in the language_screenshots scenarios.

Change-Id: If822f1b2b8bda4d233dff5a88f6317ee1b0d57f1
2015-01-27 13:35:39 -08:00
Amir E. Aharoni 401c526d8a [BrowserTest] Remove extra empty lines to make Rubocop pass
Change-Id: I30be711ee021af3d33b52a957bddd6e76b23b9ae
2015-01-27 11:09:16 -08:00
Amir E. Aharoni c80e311a02 [BrowserTest] Fix VisualEditor toolbar actions scenario
The save button changed from constructive (green) to progressive (blue).

Change-Id: Ic410d5ed3847da803d6d83df7f77b6e0edc5d81b
2015-01-27 04:15:51 +00:00
Amir E. Aharoni 896c8b5d5f [BrowserTest] Change "Headings interface" to "Headings menu"
Change-Id: I8a50bdf1c49d80ec89c1d87d2a4e353f0aa1a3f9
2015-01-27 04:15:43 +00:00