cfpb / regulations-site

(DEPRECATED) Web interface for viewing U.S. federal regulations and other regulatory information
Other
28 stars 43 forks source link

Update functional tests #839

Closed niqjohnson closed 6 years ago

niqjohnson commented 6 years ago

Update functional tests to more fully check that the eRegs user interface is working as expected

Additions

Changes

Testing

  1. Break out those terminal tabs!
    1. In one tab, start up regulations-site (e.g. python manage.py runserver 8001)
    2. In a second tab, go to the root of regulations-site and start up the dummy API with ./dummy_api/start.sh 0.0.0.0:8282 (or whatever port you usually run the real API from regulations-core on)
    3. In a third tab, start up Sauce Connect however you usually do that
  2. Visit http://localhost:8001/ (or whatever port you're running regulations-site on) in a browser; you should see only a single regulation, 1005, on the home screen, and all the content for that regulation should be placeholder gibberish
  3. In a fourth terminal tab, go to the root of regulations-site and run grunt test
  4. Waaaaaaaaiiiiiiit for all the functional tests to run in both Chrome and IE on Sauce Labs (it'll take 6–7 minutes for everything to finish)
  5. Verify that all the tests pass
  6. If you want to, log into Sauce Labs to watch the recordings of the tests to make sure they're doing the right things

Screenshots

You should see this in your terminal when grunt test finishes:

eregs-terminal

Notes

Todos

ascott1 commented 6 years ago

Approved on my end. Let's see this 👶 merged!