From c0f4b82f1bd86a0a557bcab228bdf72cbd9db2bc Mon Sep 17 00:00:00 2001 From: Timo Stollenwerk Date: Wed, 10 Jul 2013 08:36:51 +0200 Subject: [PATCH] levenshtein_distance is a float. Fix test. Sorry for the noise, I currently can't run the tests on my local machine. --- src/collective/solr/exportimport.py | 2 +- src/collective/solr/profiles/default/solr.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/collective/solr/exportimport.py b/src/collective/solr/exportimport.py index 8aa4b09..2c2e707 100644 --- a/src/collective/solr/exportimport.py +++ b/src/collective/solr/exportimport.py @@ -134,7 +134,7 @@ class SolrConfigXMLAdapter(XMLAdapterBase): value.append(elem.getAttribute('name')) self.context.field_list = tuple(map(str, value)) elif child.nodeName == 'levenshtein_distance': - value = int(str(child.getAttribute('value'))) + value = float(str(child.getAttribute('value'))) self.context.levenshtein_distance = value def _createNode(self, name, value): diff --git a/src/collective/solr/profiles/default/solr.xml b/src/collective/solr/profiles/default/solr.xml index 6c1abd1..a0dfc66 100644 --- a/src/collective/solr/profiles/default/solr.xml +++ b/src/collective/solr/profiles/default/solr.xml @@ -33,6 +33,6 @@ value="]" /> - +