Skip to content

Commit

Permalink
feat(fra-single-quote-title): Supports for single quotes in personal …
Browse files Browse the repository at this point in the history
…title (#54)
  • Loading branch information
Joxit authored Jul 1, 2019
1 parent 3dfd16b commit cd87ea4
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 1 deletion.
2 changes: 1 addition & 1 deletion classifier/PersonalTitleClassifier.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ module.exports.tests.contains_numerals = (test) => {
module.exports.tests.classify = (test) => {
let valid = [
'Général', 'General', 'gal',
'Saint', 'st', 'cdt'
'Saint', 'st', 'cdt', 'l\'Amiral'
]

valid.forEach(token => {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
l'amiral
adjudant|l'adjudant
empereur|l'empereur
inspecteur|l'inspecteur
16 changes: 16 additions & 0 deletions test/address.fra.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,22 @@ const testcase = (test, common) => {
assert('École Jules Vernes Villetaneuse', [
{ place: 'École Jules Vernes' }, { locality: 'Villetaneuse' }
])

assert(`Rue de l'Amiral Galache, Toulouse`, [
{ street: `Rue de l'Amiral Galache` }, { locality: 'Toulouse' }
])

assert(`Rue de l'Inspecteur Alles Paris`, [
{ street: `Rue de l'Inspecteur Alles` }, { locality: 'Paris' }
])

assert(`Rue de l'Empereur Julien Paris`, [
{ street: `Rue de l'Empereur Julien` }, { locality: 'Paris' }
])

assert(`Rue de l'Adjudant Réau Paris`, [
{ street: `Rue de l'Adjudant Réau` }, { locality: 'Paris' }
])
}

module.exports.all = (tape, common) => {
Expand Down

0 comments on commit cd87ea4

Please sign in to comment.