Skip to content

Commit

Permalink
Fix #3: incorrect plural for macros
Browse files Browse the repository at this point in the history
  • Loading branch information
TotalVerb committed Feb 20, 2017
1 parent cb89fd0 commit a61772a
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 32 deletions.
2 changes: 1 addition & 1 deletion src/pluralize.jl
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ const A17 = Set([
"albino", "generalissimo", "manifesto", "archipelago", "ghetto", "medico",
"armadillo", "guano", "octavo", "commando", "inferno", "photo", "ditto",
"jumbo", "pro", "dynamo", "lingo", "quarto", "embryo", "lumbago", "rhino",
"fiasco", "magneto", "stylo"])
"fiasco", "magneto", "stylo", "macro"])

# table A.18 -o to -os (ang.) or -i (cls)
const A18 = Set([
Expand Down
31 changes: 31 additions & 0 deletions test/pluralize.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
@testset "Pluralize" begin
@test pluralize("agency") == "agencies"
@test pluralize("bacterium") == "bacteria"
@test pluralize("bison") == "bison"
@test pluralize("cactus") == "cacti"
@test pluralize("child") == "children"
@test pluralize("corps") == "corps"
@test pluralize("cow") == "kine"
@test pluralize("datum") == "data"
@test pluralize("deer") == "deer"
@test pluralize("diagnosis") == "diagnoses"
@test pluralize("die") == "dice"
@test pluralize("elf") == "elves"
@test pluralize("fish") == "fish"
@test pluralize("focus") == "foci"
@test pluralize("foot") == "feet"
@test pluralize("formula") == "formulae"
@test pluralize("genius") == "genii"
@test pluralize("goose") == "geese"
@test pluralize("graffito") == "graffiti"
@test pluralize("iron") == "irons"
@test pluralize("louse") == "lice"
@test pluralize("man") == "men"
@test pluralize("macro") == "macros"
@test pluralize("money") == "monies"
@test pluralize("octopus") == "octopodes" # "octopi" not standard Latin
@test pluralize("pig") == "pigs"
@test pluralize("suffix") == "suffixes" # "suffices" not standard Latin
@test pluralize("unicorn") == "unicorns"
@test pluralize("vertex") == "vertices"
end
32 changes: 1 addition & 31 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -71,37 +71,7 @@ end
end
end

@testset "Pluralize" begin
@test pluralize("agency") == "agencies"
@test pluralize("bacterium") == "bacteria"
@test pluralize("bison") == "bison"
@test pluralize("cactus") == "cacti"
@test pluralize("child") == "children"
@test pluralize("corps") == "corps"
@test pluralize("cow") == "kine"
@test pluralize("datum") == "data"
@test pluralize("deer") == "deer"
@test pluralize("diagnosis") == "diagnoses"
@test pluralize("die") == "dice"
@test pluralize("elf") == "elves"
@test pluralize("fish") == "fish"
@test pluralize("focus") == "foci"
@test pluralize("foot") == "feet"
@test pluralize("formula") == "formulae"
@test pluralize("genius") == "genii"
@test pluralize("goose") == "geese"
@test pluralize("graffito") == "graffiti"
@test pluralize("iron") == "irons"
@test pluralize("louse") == "lice"
@test pluralize("man") == "men"
@test pluralize("money") == "monies"
@test pluralize("octopus") == "octopodes" # "octopi" not standard Latin
@test pluralize("pig") == "pigs"
@test pluralize("suffix") == "suffixes" # "suffices" not standard Latin
@test pluralize("unicorn") == "unicorns"
@test pluralize("vertex") == "vertices"
end

include("pluralize.jl")
include("list.jl")
include("text.jl")
include("quantity.jl")

0 comments on commit a61772a

Please sign in to comment.