Skip to content

Commit 30ea7b1

Browse files
committed
revert name change
1 parent 55cdc5c commit 30ea7b1

4 files changed

Lines changed: 39 additions & 39 deletions

File tree

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name = "HanziRomanization"
1+
name = "Hanzi"
22
uuid = "485a87e4-fb71-42ca-b614-bc87b1bb3702"
33
authors = ["Nicolas Cloutier <nicocloutier1@gmai.com>"]
44
version = "1.0.0"

README.md

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# HanziRomanization.jl
1+
# Hanzi.jl
22

33
[![Build Status](https://github.com/NicoACloutier/Hanzi.jl/actions/workflows/CI.yml/badge.svg?branch=main)](https://github.com/NicoACloutier/Hanzi.jl/actions/workflows/CI.yml?query=branch%3Amain)
44

@@ -15,25 +15,25 @@ This library requires a minimum of Julia 1.0 and does not depend on any external
1515
### Usage examples
1616

1717
```julia
18-
using HanziRomanization
19-
20-
HanziRomanization.pinyin("") # [["qiū"]]
21-
HanziRomanization.pinyin("", multiple=true) # [["qiū"]]
22-
HanziRomanization.pinyin("") # [["shì"]]
23-
HanziRomanization.pinyin("", multiple=true) # [["shì", "tí"]]
24-
HanziRomanization.pinyin("你好") # [["nǐ"], ["hǎo"]]
25-
HanziRomanization.pinyin("你好", multiple=true) # [["nǐ"], ["hǎo", "hào"]]
26-
HanziRomanization.pinyin("我叫John。你呢?") # [["wǒ"], ["jiào"], ["John。"], ["nǐ"], ["ne"], ["?"]]
27-
HanziRomanization.pinyin("我叫John。你呢?", multiple=true) # [["wǒ"], ["jiào"], ["John。"], ["nǐ"], ["ne", "ní", "nǐ", "nī"], ["?"]]
28-
29-
HanziRomanization.wadegiles("") # [["ch'iu1"]]
30-
HanziRomanization.wadegiles("", multiple=true) # [["ch'iu1"]]
31-
HanziRomanization.wadegiles("") # [["shih4"]]
32-
HanziRomanization.wadegiles("", multiple=true) # [["shih4", "t'i2"]]
33-
HanziRomanization.wadegiles("你好") # [["ni3"], ["hao3"]]
34-
HanziRomanization.wadegiles("你好", multiple=true) # [["ni3"], ["hao3", "hao4"]]
35-
HanziRomanization.wadegiles("我叫John。你呢?") # [["wo3"], ["chiao4"], ["John。"], ["ni3"], ["ne"], ["?"]]
36-
HanziRomanization.wadegiles("我叫John。你呢?", multiple=true) # [["wo3"], ["chiao4"], ["John。"], ["ni3"], ["ne", "ni2", "ni3", "ni1"], ["?"]]
18+
using Hanzi
19+
20+
Hanzi.pinyin("") # [["qiū"]]
21+
Hanzi.pinyin("", multiple=true) # [["qiū"]]
22+
Hanzi.pinyin("") # [["shì"]]
23+
Hanzi.pinyin("", multiple=true) # [["shì", "tí"]]
24+
Hanzi.pinyin("你好") # [["nǐ"], ["hǎo"]]
25+
Hanzi.pinyin("你好", multiple=true) # [["nǐ"], ["hǎo", "hào"]]
26+
Hanzi.pinyin("我叫John。你呢?") # [["wǒ"], ["jiào"], ["John。"], ["nǐ"], ["ne"], ["?"]]
27+
Hanzi.pinyin("我叫John。你呢?", multiple=true) # [["wǒ"], ["jiào"], ["John。"], ["nǐ"], ["ne", "ní", "nǐ", "nī"], ["?"]]
28+
29+
Hanzi.wadegiles("") # [["ch'iu1"]]
30+
Hanzi.wadegiles("", multiple=true) # [["ch'iu1"]]
31+
Hanzi.wadegiles("") # [["shih4"]]
32+
Hanzi.wadegiles("", multiple=true) # [["shih4", "t'i2"]]
33+
Hanzi.wadegiles("你好") # [["ni3"], ["hao3"]]
34+
Hanzi.wadegiles("你好", multiple=true) # [["ni3"], ["hao3", "hao4"]]
35+
Hanzi.wadegiles("我叫John。你呢?") # [["wo3"], ["chiao4"], ["John。"], ["ni3"], ["ne"], ["?"]]
36+
Hanzi.wadegiles("我叫John。你呢?", multiple=true) # [["wo3"], ["chiao4"], ["John。"], ["ni3"], ["ne", "ni2", "ni3", "ni1"], ["?"]]
3737
```
3838

3939
## Special thanks
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
module HanziRomanization
1+
module Hanzi
22
export wadegiles, pinyin
33

44
include("convert.jl")

test/runtests.jl

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
1-
using HanziRomanization
1+
using Hanzi
22
using Test
33

44
@testset "Hanzi.jl" begin
55
# PINYIN TESTS
6-
@test HanziRomanization.pinyin("") == [["qiū"]] # test single character `multiple=false` singular pronunciation
7-
@test HanziRomanization.pinyin("", multiple=true) == [["qiū"]] # test single character `multiple=true` singular pronunciation
8-
@test HanziRomanization.pinyin("") == [["shì"]] # test single character `multiple=false` multiple pronunciations
9-
@test HanziRomanization.pinyin("", multiple=true) == [["shì", ""]] # test single character `multiple=true` multiple pronunciations
10-
@test HanziRomanization.pinyin("你好") == [[""], ["hǎo"]] # test multiple characters `multiple=false` multiple pronunciations
11-
@test HanziRomanization.pinyin("你好", multiple=true) == [[""], ["hǎo", "hào"]] # test multiple characters `multiple=true` multiple pronunciations
12-
@test HanziRomanization.pinyin("我叫John。你呢?") == [[""], ["jiào"], ["John。"], [""], ["ne"], [""]] # test multiple characters `multiple=false` multiple pronunciations non-recognized glyphs
13-
@test HanziRomanization.pinyin("我叫John。你呢?", multiple=true) == [[""], ["jiào"], ["John。"], [""], ["ne", "", "", ""], [""]] # test multiple characters `multiple=true` multiple pronunciations non-recognized glyphs
6+
@test Hanzi.pinyin("") == [["qiū"]] # test single character `multiple=false` singular pronunciation
7+
@test Hanzi.pinyin("", multiple=true) == [["qiū"]] # test single character `multiple=true` singular pronunciation
8+
@test Hanzi.pinyin("") == [["shì"]] # test single character `multiple=false` multiple pronunciations
9+
@test Hanzi.pinyin("", multiple=true) == [["shì", ""]] # test single character `multiple=true` multiple pronunciations
10+
@test Hanzi.pinyin("你好") == [[""], ["hǎo"]] # test multiple characters `multiple=false` multiple pronunciations
11+
@test Hanzi.pinyin("你好", multiple=true) == [[""], ["hǎo", "hào"]] # test multiple characters `multiple=true` multiple pronunciations
12+
@test Hanzi.pinyin("我叫John。你呢?") == [[""], ["jiào"], ["John。"], [""], ["ne"], [""]] # test multiple characters `multiple=false` multiple pronunciations non-recognized glyphs
13+
@test Hanzi.pinyin("我叫John。你呢?", multiple=true) == [[""], ["jiào"], ["John。"], [""], ["ne", "", "", ""], [""]] # test multiple characters `multiple=true` multiple pronunciations non-recognized glyphs
1414

1515
# WADE-GILES TESTS
16-
@test HanziRomanization.wadegiles("") == [["ch'iu1"]] # test single character `multiple=false` singular pronunciation
17-
@test HanziRomanization.wadegiles("", multiple=true) == [["ch'iu1"]] # test single character `multiple=true` singular pronunciation
18-
@test HanziRomanization.wadegiles("") == [["shih4"]] # test single character `multiple=false` multiple pronunciations
19-
@test HanziRomanization.wadegiles("", multiple=true) == [["shih4", "t'i2"]] # test single character `multiple=true` multiple pronunciations
20-
@test HanziRomanization.wadegiles("你好") == [["ni3"], ["hao3"]] # test multiple characters `multiple=false` multiple pronunciations
21-
@test HanziRomanization.wadegiles("你好", multiple=true) == [["ni3"], ["hao3", "hao4"]] # test multiple characters `multiple=true` multiple pronunciations
22-
@test HanziRomanization.wadegiles("我叫John。你呢?") == [["wo3"], ["chiao4"], ["John。"], ["ni3"], ["ne"], [""]] # test multiple characters `multiple=false` multiple pronunciations non-recognized glyphs
23-
@test HanziRomanization.wadegiles("我叫John。你呢?", multiple=true) == [["wo3"], ["chiao4"], ["John。"], ["ni3"], ["ne", "ni2", "ni3", "ni1"], [""]] # test multiple characters `multiple=true` multiple pronunciations non-recognized glyphs
16+
@test Hanzi.wadegiles("") == [["ch'iu1"]] # test single character `multiple=false` singular pronunciation
17+
@test Hanzi.wadegiles("", multiple=true) == [["ch'iu1"]] # test single character `multiple=true` singular pronunciation
18+
@test Hanzi.wadegiles("") == [["shih4"]] # test single character `multiple=false` multiple pronunciations
19+
@test Hanzi.wadegiles("", multiple=true) == [["shih4", "t'i2"]] # test single character `multiple=true` multiple pronunciations
20+
@test Hanzi.wadegiles("你好") == [["ni3"], ["hao3"]] # test multiple characters `multiple=false` multiple pronunciations
21+
@test Hanzi.wadegiles("你好", multiple=true) == [["ni3"], ["hao3", "hao4"]] # test multiple characters `multiple=true` multiple pronunciations
22+
@test Hanzi.wadegiles("我叫John。你呢?") == [["wo3"], ["chiao4"], ["John。"], ["ni3"], ["ne"], [""]] # test multiple characters `multiple=false` multiple pronunciations non-recognized glyphs
23+
@test Hanzi.wadegiles("我叫John。你呢?", multiple=true) == [["wo3"], ["chiao4"], ["John。"], ["ni3"], ["ne", "ni2", "ni3", "ni1"], [""]] # test multiple characters `multiple=true` multiple pronunciations non-recognized glyphs
2424
end

0 commit comments

Comments
 (0)