diff --git a/spec/stores/draft-store-spec.coffee b/spec/stores/draft-store-spec.coffee index fd628c942..fedf8a3fc 100644 --- a/spec/stores/draft-store-spec.coffee +++ b/spec/stores/draft-store-spec.coffee @@ -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 diff --git a/src/deprecate-utils.coffee b/src/deprecate-utils.coffee index cab91d881..4200b53b0 100644 --- a/src/deprecate-utils.coffee +++ b/src/deprecate-utils.coffee @@ -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(