Commit Graph

68 Commits (41d6995da499f70b1acb878e6be3b6b4c81cd033)

Author SHA1 Message Date
David Baker 161978ab05 Fix tests 2016-12-16 15:20:52 +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
David Baker 3938abc5dd add webkit vendor prefixed properties
for mavericks safari
2016-09-23 17:18:52 +01:00
David Baker d0618c4f49 Update test now that /publicRooms is a post 2016-09-16 20:49:28 +01: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 dd6868c255 Fix joining test
This had been broken by
https://github.com/matrix-org/matrix-react-sdk/pull/399. Change the way we
populate the matrixclient used for the joining tests.
2016-08-10 22:39:53 +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
David Baker c9ab977d73 Fix unit tests
ReplaceUsingAccessToken was, uh, replaced with replacedUsingCreds
2016-08-05 14:38:10 +01:00
David Baker 607923b58f Fix test since we peek by room ID, not alias 2016-06-17 17:49:36 +01:00
Richard van der Hoff bf31d6d5fa Karma test tweaks
* Make sure we only get one js-sdk (and update runtime config to match)
* Don't verifyNoOutstandingRequests (since it is hard to be certain which we
  will get, and makes the tests too dependent on implementation-specifics).
* Disable color for npm test, to avoid confusing Jenkins
2016-04-13 17:41:23 +01:00
Richard van der Hoff 181a6a61ff tests: Don't add the div to the DOM 2016-04-13 17:20:06 +01:00
Richard van der Hoff 322af6513d Run some tests under karma
Including a regression test for
https://github.com/vector-im/vector-web/issues/1314
2016-04-13 17:20:06 +01:00
Richard van der Hoff 69ce3c43cf Revert "Merge branch 'develop' into rav/karma"
The karma tests don't pass yet, and aren't ready to land on develop.

This reverts commit 438453e61a, reversing
changes made to 50f94eb040.
2016-04-13 17:17:45 +01:00
Richard van der Hoff a512e600a7 tests: Don't add the div to the DOM 2016-04-13 11:16:38 +01:00
Richard van der Hoff 429d110212 Run some tests under karma
Including a regression test for
https://github.com/vector-im/vector-web/issues/1314
2016-04-13 10:15:04 +01:00