mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-01-04 07:10:06 +08:00
fix(warnings): Remove deprecate warnings from specs
This commit is contained in:
parent
64d0d60f8b
commit
fc69d2dbf6
2 changed files with 7 additions and 6 deletions
|
@ -6,12 +6,13 @@ ModelQuery = require '../../src/flux/models/query'
|
|||
AccountStore = require '../../src/flux/stores/account-store'
|
||||
DatabaseStore = require '../../src/flux/stores/database-store'
|
||||
DraftStore = require '../../src/flux/stores/draft-store'
|
||||
ComposerExtension = require '../../src/flux/extensions/composer-extension'
|
||||
ComposerExtension = require '../../flux/src/extensions/composer-extension'
|
||||
SendDraftTask = require '../../src/flux/tasks/send-draft'
|
||||
DestroyDraftTask = require '../../src/flux/tasks/destroy-draft'
|
||||
SoundRegistry = require '../../src/sound-registry'
|
||||
Actions = require '../../src/flux/actions'
|
||||
Utils = require '../../src/flux/models/utils'
|
||||
ExtensionRegistry = require '../../src/extension-registry'
|
||||
|
||||
InlineStyleTransformer = require '../../src/services/inline-style-transformer'
|
||||
SanitizeTransformer = require '../../src/services/sanitize-transformer'
|
||||
|
@ -389,9 +390,9 @@ describe "DraftStore", ->
|
|||
|
||||
describe "extensions", ->
|
||||
beforeEach ->
|
||||
DraftStore.registerExtension(TestExtension)
|
||||
ExtensionRegistry.Composer.register(TestExtension)
|
||||
afterEach ->
|
||||
DraftStore.unregisterExtension(TestExtension)
|
||||
ExtensionRegistry.Composer.unregister(TestExtension)
|
||||
|
||||
it "should give extensions a chance to customize the draft via ext.prepareNewDraft", ->
|
||||
@_callNewMessageWithContext {threadId: fakeThread.id}
|
||||
|
@ -821,9 +822,9 @@ describe "DraftStore", ->
|
|||
|
||||
describe "extensions", ->
|
||||
beforeEach ->
|
||||
DraftStore.registerExtension(TestExtension)
|
||||
ExtensionRegistry.Composer.register(TestExtension)
|
||||
afterEach ->
|
||||
DraftStore.unregisterExtension(TestExtension)
|
||||
ExtensionRegistry.Composer.unregister(TestExtension)
|
||||
|
||||
it "should give extensions a chance to customize the draft via ext.prepareNewDraft", ->
|
||||
received = null
|
||||
|
|
|
@ -5,7 +5,7 @@ class DeprecateUtils
|
|||
console.warn message if condition
|
||||
|
||||
@deprecate: (fnName, newName, ctx, fn) ->
|
||||
if NylasEnv.inDevMode
|
||||
if NylasEnv.inDevMode() and not NylasEnv.inSpecMode()
|
||||
warn = true
|
||||
newFn = =>
|
||||
DeprecateUtils.warn(
|
||||
|
|
Loading…
Reference in a new issue