From d7f4d39aa2631e407585dd6f5b48138d8343026e Mon Sep 17 00:00:00 2001 From: Raul Ochoa Date: Thu, 28 Dec 2017 18:09:41 +0000 Subject: [PATCH] Don't not override the full client but only the provided methods --- test/unit/cartodb/ported/tile_stats.test.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/unit/cartodb/ported/tile_stats.test.js b/test/unit/cartodb/ported/tile_stats.test.js index 3fbf93ec..a2d30cd0 100644 --- a/test/unit/cartodb/ported/tile_stats.test.js +++ b/test/unit/cartodb/ported/tile_stats.test.js @@ -11,7 +11,7 @@ describe('tile stats', function() { }); afterEach(function() { - global.statsClient = this.statsClient; + global.statsClient = this.statsClient; }); it('finalizeGetTileOrGrid does not call statsClient when format is not supported', function() { @@ -84,7 +84,7 @@ describe('tile stats', function() { }); function mockStatsClientGetInstance(instance) { - global.statsClient = instance; + global.statsClient = Object.assign(global.statsClient, instance); } });