Commit Graph

13 Commits (523b315985299e5b65d00bf4331eff8caaad4f09)

Author SHA1 Message Date
Luke Barnard e40d3852ff Fix tests to reflect recent changes
This is an attempt to reduce flakiness (see https://github.com/matrix-org/matrix-react-sdk/pull/781 also)
2017-03-29 16:07:11 +01:00
David Baker c4d3d66f31 Support for phone number registration/signin, mk2
Changes from https://github.com/vector-im/riot-web/pull/3381
2017-03-14 14:45:54 +00:00
Richard van der Hoff e5b3ec83b3 Revert "Support for phone number registration / signin (#3381)"
This reverts commit 271fedd1e9.

This breaks against the current synapse release. We need to think more
carefully about backwards compatibility.
2017-03-09 20:41:11 +00:00
David Baker 271fedd1e9 Support for phone number registration / signin (#3381)
* WIP msisdn signin (css)

* Changed how highlights are done

to support keyboard based navigation

* Support for new InteractiveAuth registration

* CSS for msisdn auth entry component

* CSS tweaks for msisdn login

* Fix tests
2017-03-09 10:58:58 +00:00
Richard van der Hoff 5368c87dc1 Fix tests to run crypto code
Return a device_id from /login requests, so that all the crypto logic works.
2017-02-02 23:41:49 +00:00
Richard van der Hoff fe64b04339 More test resilience
Give the tests more than one chance for the roomview to load.
2017-01-24 13:35:41 +00:00
Richard van der Hoff 597705716b Hopefully, fix intermittent test failure
This seeks to fix the intermittent failure of the "MatrixClient rehydrated from
stored credentials" tests.

The problem appears to be that the 'load_completed' is sometimes taking a while
to come through from the dispatcher - or rather, it is taking a long time to
get *sent* to the dispatcher: the chain of `q().then().catch().done()` in
componentDidMount can take a while to happen.

As a workaround, give the test a few goes when waiting for us to start
syncing. It's not ideal to be poking into the internal state of MatrixChat like
this, but it'll do for now.
2017-01-24 11:26:09 +00:00
David Baker 67cf4230ac Fix broken tests
Promises are now not being resolved within the same tick, so give
another tick for the UI to update after all the HTTP calls have
flushed through. This is fairly terrible, but I can't immediately
see a better way of doing this.
2016-12-09 14:27:41 +00:00
David Baker d65374f7f9 Make the 'loading' tests work in isolation
The 'loading' tests only worked when run with the other tests and
failed if you just ran the file by itself, because the skin was
loading in the 'joining' tests, but not here.
2016-12-09 10:31:26 +00:00
Richard van der Hoff 244265d52b Make sure that we clear localstorage before *all* tests
This was causing flaky tests, as sometimes the joining test would inherit an
"mx_is_guest" setting from a previous test run.
2016-08-11 11:42:29 +01:00
Richard van der Hoff da7a556629 More tests for the loading process:
1. Check that localstorage is correctly updated on successful login (test for
   https://github.com/matrix-org/matrix-react-sdk/pull/404)

2. Check that the saved HS isused for guest registration (test for
   https://github.com/matrix-org/matrix-react-sdk/pull/405)

3. Test loginToken handling (test for
   https://github.com/matrix-org/matrix-react-sdk/pull/406 /
   https://github.com/vector-im/vector-web/pull/1946)
2016-08-11 02:00:27 +01:00
Richard van der Hoff fe4bb3e413 More app-loading tests
1. fix the 'Clean load' tests which had been broken by
https://github.com/matrix-org/matrix-react-sdk/pull/399: make sure we clear
localStorage between tests.

2. Test the session rehydration properly by setting the localStorage rather
than setting up the MatrixClientPeg before loading the app.

3. Add some tests for the auto-guest-registration flows.
2016-08-10 14:37:30 +01:00
Richard van der Hoff afc889ff4d Some tests of the application load process 2016-08-10 00:15:04 +01:00