Skip to content

Commit 75cb64f

Browse files
authored
Merge pull request #13 from jakewilliami/dev
Dev
2 parents 51fcbff + e048afe commit 75cb64f

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "SpelledOut"
22
uuid = "4728c690-e668-4265-bc0d-51a8c0f93067"
33
authors = ["Jake W. Ireland <[email protected]> and contributors"]
4-
version = "0.1.1"
4+
version = "1.0.1"
55

66
[compat]
77
julia = "1"

src/SpelledOut.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ function small_convert(number::Integer; british::Bool=false, dict::Symbol=:moder
1414
return word
1515
end
1616

17-
v = 1
17+
v = 0
1818
while v < length(_tens)
1919
d_cap = _tens[v + 1]
2020
d_number = BigInt(20 + 10 * v)

test/runtests.jl

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,15 @@ using Test
1515
@test Spelled_out(1234) == "One thousand, two hundred thirty-four"
1616
@test Spelled_Out(1234) == "One Thousand, Two Hundred Thirty-Four"
1717
@test SPELLED_OUT(1234) == "ONE THOUSAND, TWO HUNDRED THIRTY-FOUR"
18-
@test spelled_out(123456789) == "one hundred thirty-three million, four hundred fifty-six thousand, seven hundred eighty-nine"
19-
@test spelled_out(123456789, british=true) == "one hundred and thirty-three million, four hundred and fifty-six thousand, seven hundred and eighty-nine"
18+
@test spelled_out(123456789) == "one hundred twenty-three million, four hundred fifty-six thousand, seven hundred eighty-nine"
19+
@test spelled_out(123456789, british=true) == "one hundred and twenty-three million, four hundred and fifty-six thousand, seven hundred and eighty-nine"
2020
@test spelled_out(0) == "zero"
2121
@test spelled_out(0, british=true) == "zero"
2222
@test spelled_out(100) == "one hundred"
2323
@test spelled_out(100, british=true) == "one hundred"
24-
@test spelled_out(123456789, british=true, dict=:european) == "one hundred and thirty-three million, four hundred and fifty-six thousand, seven hundred and eighty-nine"
25-
@test spelled_out(123456789, dict=:european) == "one hundred thirty-three million, four hundred fifty-six thousand, seven hundred eighty-nine"
26-
@test spelled_out(123456789, british=true, dict=:british) == "one hundred and thirty-three million, four hundred and fifty-six thousand, seven hundred and eighty-nine"
27-
@test spelled_out(1234567890123, british=true, dict=:british) == "one billion, two hundred and thirty-four thousand million, five hundred and sixty-seven million, eight hundred and ninety thousand, one hundred and thirty-three"
28-
@test spelled_out(1234567890123, british=true, dict=:modern) == "one trillion, two hundred and thirty-four billion, five hundred and sixty-seven million, eight hundred and ninety thousand, one hundred and thirty-three"
24+
@test spelled_out(123456789, british=true, dict=:european) == "one hundred and twenty-three million, four hundred and fifty-six thousand, seven hundred and eighty-nine"
25+
@test spelled_out(123456789, dict=:european) == "one hundred twenty-three million, four hundred fifty-six thousand, seven hundred eighty-nine"
26+
@test spelled_out(123456789, british=true, dict=:british) == "one hundred and twenty-three million, four hundred and fifty-six thousand, seven hundred and eighty-nine"
27+
@test spelled_out(1234567890123, british=true, dict=:british) == "one billion, two hundred and thirty-four thousand million, five hundred and sixty-seven million, eight hundred and ninety thousand, one hundred and twenty-three"
28+
@test spelled_out(1234567890123, british=true, dict=:modern) == "one trillion, two hundred and thirty-four billion, five hundred and sixty-seven million, eight hundred and ninety thousand, one hundred and twenty-three"
2929
end

0 commit comments

Comments
 (0)