You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-08-09 08:42:50 +03:00
replace expect.createSpy() with jest.fn()
Signed-off-by: Stephen Solka <stephen0q@gmail.com>
This commit is contained in:
committed by
J. Ryan Stinnett
parent
c3185a4cdb
commit
0bb35944f9
@@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
const jest = require('jest-mock');
|
||||
const React = require('react');
|
||||
const ReactDOM = require('react-dom');
|
||||
const ReactTestUtils = require('react-addons-test-utils');
|
||||
@@ -87,8 +88,8 @@ describe('Registration', function() {
|
||||
});
|
||||
|
||||
it('should NOT track a referral following successful registration of a non-team member', function(done) {
|
||||
const onLoggedIn = expect.createSpy().andCall(function(creds, teamToken) {
|
||||
expect(teamToken).toNotExist();
|
||||
const onLoggedIn = jest.fn(function(creds, teamToken) {
|
||||
expect(teamToken).toBeFalsy();
|
||||
done();
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user