From 08b19df06d95fe7918f9eebb8e597612fccfc8b6 Mon Sep 17 00:00:00 2001 From: Rob Hudson Date: Thu, 5 Sep 2013 11:32:53 -0700 Subject: [PATCH] wip --- apps/amo/tests/__init__.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/apps/amo/tests/__init__.py b/apps/amo/tests/__init__.py index caf59e9e5a..4363b48b33 100644 --- a/apps/amo/tests/__init__.py +++ b/apps/amo/tests/__init__.py @@ -742,6 +742,12 @@ class ESTestCase(TestCase): % e.args[0]] + list(e.args[1:])) raise + cls._SEARCH_ANALYZER_MAP = amo.SEARCH_ANALYZER_MAP + amo.SEARCH_ANALYZER_MAP = { + 'english': ['en-us'], + 'spanish': ['es'], + } + for index in set(settings.ES_INDEXES.values()): # Get the index that's pointed to by the alias. try: @@ -777,6 +783,7 @@ class ESTestCase(TestCase): if a.type == amo.ADDON_WEBAPP]) unindex_addons([a.id for a in cls._addons if a.type != amo.ADDON_WEBAPP]) + amo.SEARCH_ANALYZER_MAP = cls._SEARCH_ANALYZER_MAP @classmethod def setUpIndex(cls):