diff --git a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js index f74e145865475..47392c541890e 100644 --- a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js +++ b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js @@ -73,22 +73,7 @@ describe('discover field chooser directives', function() { beforeEach(() => pluginInstance.initializeServices()); beforeEach(() => pluginInstance.initializeInnerAngular()); - beforeEach( - ngMock.module('app/discover', $provide => { - $provide.decorator('config', $delegate => { - // disable shortDots for these tests - $delegate.get = _.wrap($delegate.get, function(origGet, name) { - if (name === 'shortDots:enable') { - return false; - } else { - return origGet.call(this, name); - } - }); - - return $delegate; - }); - }) - ); + beforeEach(ngMock.module('app/discover')); beforeEach( ngMock.inject(function(Private) { diff --git a/src/legacy/core_plugins/kibana/public/discover/__tests__/doc_table/lib/rows_headers.js b/src/legacy/core_plugins/kibana/public/discover/__tests__/doc_table/lib/rows_headers.js index c19e033ccb72d..be6e9fa6a6302 100644 --- a/src/legacy/core_plugins/kibana/public/discover/__tests__/doc_table/lib/rows_headers.js +++ b/src/legacy/core_plugins/kibana/public/discover/__tests__/doc_table/lib/rows_headers.js @@ -30,7 +30,6 @@ import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logsta describe('Doc Table', function() { let $parentScope; let $scope; - let config; // Stub out a minimal mapping of 4 fields let mapping; @@ -41,8 +40,7 @@ describe('Doc Table', function() { beforeEach(() => pluginInstance.initializeInnerAngular()); beforeEach(ngMock.module('app/discover')); beforeEach( - ngMock.inject(function(_config_, $rootScope, Private) { - config = _config_; + ngMock.inject(function($rootScope, Private) { $parentScope = $rootScope; $parentScope.indexPattern = Private(FixturesStubbedLogstashIndexPatternProvider); mapping = $parentScope.indexPattern.fields; @@ -144,12 +142,6 @@ describe('Doc Table', function() { filter: sinon.spy(), maxLength: 50, }); - - // Ignore the metaFields (_id, _type, etc) since we don't have a mapping for them - sinon - .stub(config, 'get') - .withArgs('metaFields') - .returns([]); }); afterEach(function() { destroy(); @@ -215,10 +207,11 @@ describe('Doc Table', function() { maxLength: 50, }); + /** sinon .stub(config, 'get') .withArgs('metaFields') - .returns(['_id']); + .returns(['_id']); **/ // Open the row $scope.toggleRow();