From 06357fa3f948ed759ba15ca23d04d156eaede4c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Garc=C3=ADa=20Aubert?= Date: Mon, 7 Oct 2019 09:51:51 +0200 Subject: [PATCH] Rename named_maps_entry -> named-maps-entry --- lib/api/api-router.js | 2 +- lib/api/middlewares/surrogate-key-header.js | 2 +- lib/cache/model/{named_maps_entry.js => named-maps-entry.js} | 0 test/acceptance/cache/surrogate_keys_invalidation.js | 3 +-- test/acceptance/named_maps_authentication.js | 2 +- test/acceptance/named_maps_stats.js | 2 +- test/acceptance/templates.js | 2 +- test/unit/cartodb/cache/model/named_maps_entry.test.js | 4 ++-- 8 files changed, 8 insertions(+), 9 deletions(-) rename lib/cache/model/{named_maps_entry.js => named-maps-entry.js} (100%) diff --git a/lib/api/api-router.js b/lib/api/api-router.js index e7acb779..8c2d5063 100644 --- a/lib/api/api-router.js +++ b/lib/api/api-router.js @@ -28,7 +28,7 @@ const SurrogateKeysCache = require('../cache/surrogate_keys_cache'); const VarnishHttpCacheBackend = require('../cache/backend/varnish-http'); const FastlyCacheBackend = require('../cache/backend/fastly'); const NamedMapProviderCache = require('../cache/named_map_provider_cache'); -const NamedMapsCacheEntry = require('../cache/model/named_maps_entry'); +const NamedMapsCacheEntry = require('../cache/model/named-maps-entry'); const NamedMapProviderReporter = require('../stats/reporter/named-map-provider'); const SqlWrapMapConfigAdapter = require('../models/mapconfig/adapter/sql-wrap-mapconfig-adapter'); diff --git a/lib/api/middlewares/surrogate-key-header.js b/lib/api/middlewares/surrogate-key-header.js index f616b009..b4b6c922 100644 --- a/lib/api/middlewares/surrogate-key-header.js +++ b/lib/api/middlewares/surrogate-key-header.js @@ -1,6 +1,6 @@ 'use strict'; -const NamedMapsCacheEntry = require('../../cache/model/named_maps_entry'); +const NamedMapsCacheEntry = require('../../cache/model/named-maps-entry'); const NamedMapMapConfigProvider = require('../../models/mapconfig/provider/named-map-provider'); module.exports = function setSurrogateKeyHeader ({ surrogateKeysCache }) { diff --git a/lib/cache/model/named_maps_entry.js b/lib/cache/model/named-maps-entry.js similarity index 100% rename from lib/cache/model/named_maps_entry.js rename to lib/cache/model/named-maps-entry.js diff --git a/test/acceptance/cache/surrogate_keys_invalidation.js b/test/acceptance/cache/surrogate_keys_invalidation.js index ae3e47c4..67bc64d6 100644 --- a/test/acceptance/cache/surrogate_keys_invalidation.js +++ b/test/acceptance/cache/surrogate_keys_invalidation.js @@ -6,8 +6,7 @@ var assert = require('../../support/assert'); var step = require('step'); var FastlyPurge = require('fastly-purge'); var _ = require('underscore'); - -var NamedMapsCacheEntry = require(__dirname + '/../../../lib/cache/model/named_maps_entry'); +var NamedMapsCacheEntry = require('../../../lib/cache/model/named-maps-entry'); var CartodbWindshaft = require(__dirname + '/../../../lib/server'); var nock = require('nock'); diff --git a/test/acceptance/named_maps_authentication.js b/test/acceptance/named_maps_authentication.js index f1edf5b2..6b7aac15 100644 --- a/test/acceptance/named_maps_authentication.js +++ b/test/acceptance/named_maps_authentication.js @@ -9,7 +9,7 @@ var mapnik = require('windshaft').mapnik; var CartodbWindshaft = require(__dirname + '/../../lib/server'); var serverOptions = require(__dirname + '/../../lib/server_options'); var TemplateMaps = require('../../lib/backends/template_maps.js'); -var NamedMapsCacheEntry = require('../../lib/cache/model/named_maps_entry'); +var NamedMapsCacheEntry = require('../../lib/cache/model/named-maps-entry'); describe('named maps authentication', function() { var server; diff --git a/test/acceptance/named_maps_stats.js b/test/acceptance/named_maps_stats.js index 1ad92772..10be0d91 100644 --- a/test/acceptance/named_maps_stats.js +++ b/test/acceptance/named_maps_stats.js @@ -9,7 +9,7 @@ var mapnik = require('windshaft').mapnik; var CartodbWindshaft = require(__dirname + '/../../lib/server'); var serverOptions = require(__dirname + '/../../lib/server_options'); var TemplateMaps = require('../../lib/backends/template_maps.js'); -var NamedMapsCacheEntry = require('../../lib/cache/model/named_maps_entry'); +var NamedMapsCacheEntry = require('../../lib/cache/model/named-maps-entry'); describe('named maps preview stats', function() { var server; diff --git a/test/acceptance/templates.js b/test/acceptance/templates.js index 28a76701..67901c34 100644 --- a/test/acceptance/templates.js +++ b/test/acceptance/templates.js @@ -6,7 +6,7 @@ var redis = require('redis'); var step = require('step'); var strftime = require('strftime'); var QueryTables = require('cartodb-query-tables').queryTables; -var NamedMapsCacheEntry = require('../../lib/cache/model/named_maps_entry'); +var NamedMapsCacheEntry = require('../../lib/cache/model/named-maps-entry'); var redis_stats_db = 5; // Pollute the PG environment to make sure diff --git a/test/unit/cartodb/cache/model/named_maps_entry.test.js b/test/unit/cartodb/cache/model/named_maps_entry.test.js index 35be48d1..fa6fd272 100644 --- a/test/unit/cartodb/cache/model/named_maps_entry.test.js +++ b/test/unit/cartodb/cache/model/named_maps_entry.test.js @@ -4,9 +4,9 @@ require('../../../../support/test_helper'); var assert = require('assert'); var _ = require('underscore'); -var NamedMapsCacheEntry = require('../../../../../lib/cache/model/named_maps_entry'); +var NamedMapsCacheEntry = require('../../../../../lib/cache/model/named-maps-entry'); -describe('cache named_maps_entry', function() { +describe('cache named maps entry', function() { var namedMapOwner = 'foo', namedMapName = 'wadus_name',