Skip to content

Commit

Permalink
test: add test case for multiple with surname
Browse files Browse the repository at this point in the history
  • Loading branch information
zhoulixiang committed Mar 21, 2024
1 parent 62fd375 commit 57302c8
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/multiple.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,9 @@ describe('multiple', () => {
const result = pinyin('好', { multiple: true });
expect(result).to.be.equal('hǎo hào');
});

it('[multiple]multiple+surname同时使用,多音字优先使用姓氏读音', () => {
const result = pinyin('数学家华罗庚', { mode: 'surname', multiple: true });
expect(result).to.be.equal('shù xué jiā huà luó gēng');
});
});

0 comments on commit 57302c8

Please sign in to comment.