mirror of
https://github.com/wassname/talk.git
synced 2026-08-14 12:50:17 +08:00
refactored mailer service with lodash!
This commit is contained in:
@@ -5,7 +5,7 @@ const Context = require('../../../../graph/context');
|
||||
const SettingsService = require('../../../../services/settings');
|
||||
const UserModel = require('../../../../models/user');
|
||||
const UsersService = require('../../../../services/users');
|
||||
const MailerService = require('../../../../services/mailer');
|
||||
const mailer = require('../../../../services/mailer');
|
||||
|
||||
const sinon = require('sinon');
|
||||
const chai = require('chai');
|
||||
@@ -22,7 +22,7 @@ describe('graph.mutations.banUser', () => {
|
||||
|
||||
let spy;
|
||||
before(() => {
|
||||
spy = sinon.spy(MailerService, 'send');
|
||||
spy = sinon.spy(mailer, 'send');
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
|
||||
@@ -6,7 +6,7 @@ const Context = require('../../../../graph/context');
|
||||
const SettingsService = require('../../../../services/settings');
|
||||
const UserModel = require('../../../../models/user');
|
||||
const UsersService = require('../../../../services/users');
|
||||
const MailerService = require('../../../../services/mailer');
|
||||
const mailer = require('../../../../services/mailer');
|
||||
|
||||
const sinon = require('sinon');
|
||||
const chai = require('chai');
|
||||
@@ -24,7 +24,7 @@ describe('graph.mutations.suspendUser', () => {
|
||||
|
||||
let spy;
|
||||
before(() => {
|
||||
spy = sinon.spy(MailerService, 'send');
|
||||
spy = sinon.spy(mailer, 'send');
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
|
||||
Reference in New Issue
Block a user