summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2011-12-10 11:16:55 +0800
committerPeng Wu <alexepico@gmail.com>2011-12-10 11:16:55 +0800
commit44d567eee4767c7b0bc4a2feb8cb9faaf8c83019 (patch)
tree34bd21ac9b500e2b81b70cd7321c896620fdabe5 /tests
parent3af2cf9799894048f226e952ea9a0b06f5da6553 (diff)
downloadlibpinyin-44d567eee4767c7b0bc4a2feb8cb9faaf8c83019.tar.gz
libpinyin-44d567eee4767c7b0bc4a2feb8cb9faaf8c83019.tar.xz
libpinyin-44d567eee4767c7b0bc4a2feb8cb9faaf8c83019.zip
rename pinyin to pronunciation
Diffstat (limited to 'tests')
-rw-r--r--tests/storage/test_phrase_index.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/storage/test_phrase_index.cpp b/tests/storage/test_phrase_index.cpp
index 3692828..b883c9e 100644
--- a/tests/storage/test_phrase_index.cpp
+++ b/tests/storage/test_phrase_index.cpp
@@ -28,7 +28,7 @@ int main(int argc, char * argv[]){
assert(freq == 300);
pinyin_option_t options = 0;
- gfloat poss = phrase_item.get_pinyin_possibility(options, &key1);
+ gfloat poss = phrase_item.get_pronunciation_possibility(options, &key1);
printf("pinyin possiblitiy:%f\n", poss);
assert(phrase_item.get_unigram_frequency() == 0);
@@ -51,21 +51,21 @@ int main(int argc, char * argv[]){
assert(item2.get_unigram_frequency() == 0);
assert(item2.get_n_pronunciation() == 2);
assert(item2.get_phrase_length() == 1);
- assert(item2.get_pinyin_possibility(options, &key2) == 0.75);
+ assert(item2.get_pronunciation_possibility(options, &key2) == 0.75);
}
print_time(time, bench_times);
{
PhraseItem item3;
phrase_index.get_phrase_item(1, item3);
- item3.increase_pinyin_possibility(options, &key1, 200);
- assert(item3.get_pinyin_possibility(options, &key1) == 0.5) ;
+ item3.increase_pronunciation_possibility(options, &key1, 200);
+ assert(item3.get_pronunciation_possibility(options, &key1) == 0.5) ;
}
{
PhraseItem item5;
phrase_index.get_phrase_item(1, item5);
- gfloat poss = item5.get_pinyin_possibility(options, &key1);
+ gfloat poss = item5.get_pronunciation_possibility(options, &key1);
printf("pinyin poss:%f\n", poss);
assert(poss == 0.5);
}