diff options
author | Paul Slaughter <pslaughter@gitlab.com> | 2019-05-24 13:11:29 -0500 |
---|---|---|
committer | Paul Slaughter <pslaughter@gitlab.com> | 2019-05-30 21:00:52 -0500 |
commit | 00c8264faf6e02f741240b5c430cebcebd730280 (patch) | |
tree | 4f051776be659cd41d1cf8a6f69961eee1ec98a5 /spec | |
parent | 5e88463d3089e3b764ae6347b9ce709a01acb8b7 (diff) | |
download | gitlab-ce-00c8264faf6e02f741240b5c430cebcebd730280.tar.gz |
Jestify activities spec
Also add `jQuery` to global in `test_setup`.
This was needed because:
- `vendor/jquery.endless-scroll` depends on it.
- Adding it to `global` in the spec itself didn't work.
Diffstat (limited to 'spec')
-rw-r--r-- | spec/frontend/activities_spec.js (renamed from spec/javascripts/activities_spec.js) | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/spec/javascripts/activities_spec.js b/spec/frontend/activities_spec.js index 23b6de7e4e0..d14be3a1f26 100644 --- a/spec/javascripts/activities_spec.js +++ b/spec/frontend/activities_spec.js @@ -1,7 +1,6 @@ /* eslint-disable no-unused-expressions, no-prototype-builtins, no-new, no-shadow */ import $ from 'jquery'; -import 'vendor/jquery.endless-scroll'; import Activities from '~/activities'; import Pager from '~/pager'; @@ -40,7 +39,7 @@ describe('Activities', () => { beforeEach(() => { loadFixtures(fixtureTemplate); - spyOn(Pager, 'init').and.stub(); + jest.spyOn(Pager, 'init').mockImplementation(() => {}); new Activities(); }); |