Skip to content
This repository has been archived by the owner on Dec 10, 2021. It is now read-only.

PLAT-23_behat_tests simple test for the title on the news page #27

Merged
merged 11 commits into from
Feb 18, 2016

Conversation

wagg-matt
Copy link
Contributor

First behat test

@pvhee
Copy link
Contributor

pvhee commented Feb 18, 2016

behat

@wagg-matt @gusliedke @peter-brady @Saphyel @AndyEPhipps @bimsonz @vireshpatel @vdzimwasha @girishmuraly just wanted to stress the coolness of the above

@peter-brady
Copy link
Contributor

@pvhee This is very cool. The only thing that bothers me is how we keep the tests up-to-date with constantly changing content.

I wonder if it would be possible to abstract the tests from content a little. An example would be making sure all links on a given page just resolve to a page, kind of thing.

Just thinking out loud here.

@peter-brady
Copy link
Contributor

Maybe testing on css or xpath selectors?

@wagg-matt
Copy link
Contributor Author

@peter-brady I see what you mean. I think it would be a good idea to keep these tests simple, use them for header and footer links to make they're all there and go where they need to (be good for things that are constant). Early days so far, when we have more to play with then we'll figure out more of an idea.

You can use CSS selectors and specifically drupal regions (as I've used in the above News-page feature) but this will be better to do once we have more structure and a theme in place.

@pvhee
Copy link
Contributor

pvhee commented Feb 18, 2016

@peter-brady @wagg-matt the concept of "content" needs probably to be explained:

  • we have content as added by editors (mostly directly on the live site), as it happens right now. We should never write behat tests against this as part of our automated test suite. the QA team might write tests on live content but that's a different "test suite"
  • we have fixture content that ships with config & code. We're using the default_content module for this and content is part of the codebase in JSON format. Developers own this content, and more importantly: maintain it. We can then use it for behat, for showcasing, for designing, for QA ... Read more on fixtures here for example

Fixtures: A particular environment that must be set up before a test can be run. It generally consists of setting up all test doubles and other dependencies for the software under test: such as inserting predefined data into a fake database, setting up certain directory structure in the fake file system, setting up properties on the dependencies of software under test.

pvhee added a commit that referenced this pull request Feb 18, 2016
PLAT-23_behat_tests simple test for the title on the news page
@pvhee pvhee merged commit 1082f3c into develop Feb 18, 2016
@pvhee pvhee deleted the feature/PLAT-23_behat_tests branch February 18, 2016 17:37
@pvhee pvhee mentioned this pull request Jan 5, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants