Commit graph

13 commits

Author SHA1 Message Date
Sam Smith 87ff0cae83 Tag previews acceptance tests with @integration
i.e. Allow the previews acceptance tests to be run against each Gerrit
change.

Change-Id: I17daaa955026c7fc5ef63b248c48932ecb75a1bc
2016-12-13 14:47:32 +00:00
Sam Smith 6a2f641cf4 Hygiene: Remove RL-related step
High-level acceptance tests shouldn't expose low-level concepts such as
the Resource Loader ("RL"). Merge the "And the RL module has loaded"
step into the "Given I am on the test page" step as they are only ever
used together.

Changes:
* Use the ArticlePage#wait_until_rl_module_ready helper method provided
  by mediawiki_selenium@1.7.3.
* Update and include the Gemfile.lock.

Change-Id: Ic81eae5dc0caa8ec51c91b21aef544f52d8c49e1
2016-12-13 14:46:03 +00:00
Sam Smith a0b01f86ab Hygiene: Remove "I am on the ... page" step
Merge the "Given the test page has been created" and "Given I am on the
... page" as they are only ever used together to mean "Given I am on the
test page".

Supporting changes:
* samples/links.wikitext -> fixtures/test_page.wikitext as it's more
  obvious what the file is.

Change-Id: Ide261a8e8c55133ab2a13a80c48e266252f61f5f
2016-12-13 14:25:37 +00:00
Sam Smith 4db0043ee7 Hygiene: Tidy up "core" acceptance tests
Changes:
* Rename the somewhat awkwardly named "popups_core" Cucumber feature and
  its accompanying step definitions to "previews".
* Remove as many references to Popups and HoverCards as possible.
* Use language consistent with the QUnit unit and integration tests and
  documentation, e.g. the user dwells on a link.
* Remove settings-related step definitions from the previews step
  definitions.

Change-Id: Ibc0d07e8394aeb640f9efaabfe10be5317bf4b8c
2016-12-13 14:14:08 +00:00
Sam Smith f64c6ea509 Disable QUnit and acceptance tests
Change-Id: Icee115520ec559f8e107de2946224ac1fe65154d
2016-11-08 09:31:51 +00:00
Baha cd0546beb8 Fix browser tests
The Hovercards checkbox on the beta preferences page doesn't have an ID
anymore. It has a name though, which is used from now on.

The regression was introduced in I8636f32330e23814ba3b4c0f5e22e55aaf77883e.

Bug: T148856
Change-Id: I7baa78b0d8c560ee29c3a550628bfd47cad1c30e
2016-10-24 14:27:09 -04:00
joakin eb852cacd5 Fix enabling/disabling browser tests
features/popups_settings.feature:33 seems to fail because of quick
interactions after disabling+enabling hovercards.

Setting a sleep 1 after disabling and enabling hovercards (to allow the
page to start refreshing) makes the tests more resilient

Bug: T145152
Change-Id: Iaf66aaf0e2c4f8e55419d22889f91a02891e49a1
2016-09-14 16:42:56 +00:00
Volker E 0282b9648f Hovercards: Improve layout of settings dialog to design spec
Improving Hovercards' settings dialog to fulfill design specification.
Also fixing HTML structure by removing invalid `radiogroup` element and
adding missing `</div>` element, fixing related QUnit test.

Changes:
 * Add close icon instead of using text
 * Style header as a table for alignment
 * Remove redundant "OK" button and have it replace "Save" instead
 * Update text of "OK" button to "Done"
 * Fix description for translation of "Done" button
 * Fix qunit and selenium tests
 * Remove unnecessary markup and less
 * Add mediawiki-ui-button and mediawiki-ui-icon dependencies
 * Shrink dialog width some per design spec
 * Fix dialog horizontal position calculation to remove hard-coded value

Bug: T138612
Change-Id: I7395e3438836149becdd576942bdaf6f21b4163f
2016-08-10 14:01:36 -04:00
jdlrobson feb0c76381 Render settings via template
This improves readability and separates the HTML from the
JavaScript

Change-Id: Ib765d78890b9aeb05940df00160790b01751a36b
2016-05-30 10:49:17 -07:00
Baha 85cc7e2257 QA: add a browser test to cover "enable previews" feature
Test whether:
* "Enable previews" footer link correctly appears/disappears;
* A hovercard correctly shows/doesn't show when enabled/disabled.

Bug: T133054
Change-Id: I55f311b6b8845e6ebf4cc5698758afd1f9042a45
2016-04-27 20:22:34 +00:00
Baha 728073d9e4 QA: Updates to browser tests to avoid flakiness
* Wait until the form submits successfully, verifying it
worked by testing for the notification toast.
* Drop sleep statements where possible - instead use when_present
Use one when asserting something doesn't show to avoid false positives
* Allow more time for the hovercard to show (5s) - API requests might take
longer than default time.
* Assert popups JavaScript loads before continuing with test. This
helped trap a bug in testing and will be useful for future.

Bug: T133019
Depends-On: Icb1e6ddc8f95da5e4b4de2916d292694c11ba731
Change-Id: Iacd3beedf44cadffcf0285231b2df7e5b64294f6
2016-04-20 20:02:13 +00:00
Sam Smith 6a0e108384 QA: Enable Hovercards beta feature in browser tests
Bug: T133019
Change-Id: I63faec86a756f189a40d0f61c75e33060c5395fb
2016-04-20 18:20:27 +00:00
Baha 3e78503e8e Add browser test for hovering link
Basic feature of browsing a page, hovering a link, and showing/hiding
a hovercard.

Depends-On: Ie94fa399512be041f12b2f7cada20d4206ddaf82
Bug: T133019
Change-Id: Idf39e7e2a3b343babd6d0538225b4ef9002e8ac1
2016-04-19 13:12:24 +00:00