Commit Graph

4 Commits

Author SHA1 Message Date
Martin Hanzel bd20aeb64c Add helpers to wait for axios requests
Add two methods to the axios_utils Jest mock:

- `waitFor(url)`, which returns a Promise that resolves when the
  next request to `url` finishes.
- `waitForAll()`, which returns a Promise that resolves when all
  pending requests finish.
2019-09-05 12:56:17 +00:00
Martin Hanzel be6f20d54f Fix test false passes on unmocked requests 2019-08-30 14:29:02 -04:00
Winnie Hellmann a56712433e Fix assertion in mocks_helper_spec.js 2019-08-20 18:20:21 +00:00
Martin Hanzel eb45cb8c99 Mockify jquery and axios packages
Moved the block that fails tests on unmocked axios requests from
test_setup to its own mock, and added a jQuery mock that fails
tests if they use unmocked $.ajax().
2019-07-17 17:47:39 +00:00