Jump to content

Topic on Manual talk:Coding conventions/Selenium-Ruby

How to document custom setup

4
SPage (WMF) (talkcontribs)
At the moment we tag features or scenarios that are known to fail on a clean wiki with @needs-custom-setup.

How do I communicate what a feature needs? E.g. the collapse Flow feature test only works if there are topics on the page to collapse, likewise edit_existing requires an existing post on the page. Some needs are met by running other tests first, and others require manual set up, e.g. creating a "Selenium_user" account.

Some Flow features have a sentence "Assumes the test page has content... /It requires the cldr extension..." after the Feature: Feature name line, but then in Sauce Labs' Test Session Details pages (example), this runs into the feature name in an h2 header:

Edit existing title Assumes that the test Flow page has at least two topics (with posts).: Edit existing post Flow-en.wikipedia.beta.wmflabs.org-linux-firefox#192

This post was posted by SPage (WMF), but signed as S Page (WMF).

ZFilipin (WMF) (talkcontribs)

Every scenario should be completely isolated from other scenarios. So, if a scenario needs some setup (users, pages, extensions...) it's given step(s) should take care of that. Let me know if I did not answer the question, or if you would like to pair on that.

This post was posted by ZFilipin (WMF), but signed as Zeljko.filipin(WMF).

SPage (WMF) (talkcontribs)

Well, that ideal of complete isolation isn't reality for Flow feature tests :) I've given you an example of actual assumptions that aren't in a test's given steps, so please tell me how best to express these in a test.

This post was posted by SPage (WMF), but signed as S Page (WMF).

ZFilipin (WMF) (talkcontribs)

I did not understand what is the problem. Could you please ping me via IRC or e-mail so we could arrange a pairing session?

This post was posted by ZFilipin (WMF), but signed as Zeljko.filipin(WMF).

Reply to "How to document custom setup"