Fix the automated test cases to work with the login system, and add more features to testing.

* fail-fast is now reactivated.
* API update to include reference ID in each step.
* Fix some unit tests to work with the login system.