elm-ui/tests
2018-12-30 08:44:26 -05:00
..
automation Automated Browser and App Testing 2018-12-30 08:44:26 -05:00
src Reorganize tests for easier running. 2018-12-29 11:46:16 -05:00
suite Reorganize tests for easier running. 2018-12-29 11:46:16 -05:00
Tests Reorganize tests for easier running. 2018-12-29 11:46:16 -05:00
elm.json update manual test runner to 0.19 2018-09-17 12:16:11 -04:00
gather-styles.html isVisible test 2018-09-17 16:52:51 -04:00
live.sh a stylish new design toolkit 2018-08-28 19:41:08 -04:00
Makefile Automated Browser and App Testing 2018-12-30 08:44:26 -05:00
README.md Automated Browser and App Testing 2018-12-30 08:44:26 -05:00

Elm UI Test Suite

There are two types of tests for Elm UI. The normal kind, which are located in tests/suite/

These can be run using elm-test and can be run via

elm-test

at the elm-ui root.

Layout Testing

elm-ui also needs to ensure that all layouts work as expected on all browsers.

In order to do this, we need a different testing environment.

So, the tests in elm-ui/tests/Tests will render output, then harvest bounding boxes form the browser, and run the test on the resulting data.

In order to run the test locally, compile

elm make Tests/Run.elm --output elm.js

and then open gather-styles.html

Alternatively, you can run the tests locally using selenium by running:

python3 automation/run.py --local

from the tests directory.

Running on Sauce Labs

In order to automate some of this stuff, this test can be run on Sauce Labs.

If you have an account, you'll need to create a elm-ui/sauce.env file, which has the following fields:

export SAUCE_ACCESS_KEY={your key}
export SAUCE_USERNAME={your username}

You can then run.

python3 automation/run.py

Note: The compiled elm-ui test needs to be made public somewhere in order for this to work. At the moment it's at my github.io account, though something more permanenet might be set up.

Sauce Labs References

https://wiki.saucelabs.com/display/DOCS/Platform+Configurator#/ https://wiki.saucelabs.com/display/DOCS/Sauce+Labs+Basics https://github.com/saucelabs-sample-test-frameworks/Python-Pytest-Selenium