Skip to content

Commit

Permalink
feat(normalizers): add "trim" to "peliasKeywordNormalizer" filters
Browse files Browse the repository at this point in the history
  • Loading branch information
missinglink committed Dec 13, 2019
1 parent af0929e commit cec0b19
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
3 changes: 2 additions & 1 deletion settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ function generate(){
"type": "custom",
"filter": [
"lowercase",
"icu_folding"
"icu_folding",
"trim"
]
}
},
Expand Down
5 changes: 3 additions & 2 deletions test/fixtures/expected.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
"type": "custom",
"filter": [
"lowercase",
"icu_folding"
"icu_folding",
"trim"
]
}
},
Expand Down Expand Up @@ -1184,4 +1185,4 @@
"dynamic": "strict"
}
}
}
}
3 changes: 2 additions & 1 deletion test/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ module.exports.tests.peliasKeywordNormalizer = function (test, common) {
t.equal(normalizer.type, 'custom', 'custom normalizer');
t.deepEqual(normalizer.filter, [
"lowercase",
"icu_folding"
"icu_folding",
"trim"
]);
t.end();
});
Expand Down

0 comments on commit cec0b19

Please sign in to comment.