-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* test: 테스트 한글화 * test: Add test case for empty string input in josa function * test: Add test case for empty string input in removeLastHangulCharacter function * test: Add tests for getFirstConsonants function
- Loading branch information
Showing
5 changed files
with
72 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,17 @@ | ||
import { removeLastHangulCharacter } from './removeLastHangulCharacter'; | ||
|
||
describe('removeLastHangulCharacter', () => { | ||
it('마지막 문자가 겹받침인 경우 홑받침으로 바꾼다', () => { | ||
it('마지막 문자가 겹받침인 경우 홑받침으로 바꾼다.', () => { | ||
expect(removeLastHangulCharacter('안녕하세요 값')).toBe('안녕하세요 갑'); | ||
}); | ||
it('마지막 문자가 초성과 중성의 조합으로 끝날 경우 초성만 남긴다', () => { | ||
it('마지막 문자가 초성과 중성의 조합으로 끝날 경우 초성만 남긴다.', () => { | ||
expect(removeLastHangulCharacter('프론트엔드')).toBe('프론트엔ㄷ'); | ||
}); | ||
it('마지막 문자가 초성과 중성과 종성의 조합으로 끝날 경우 초성과 중성이 조합된 문자만 남긴다.', () => { | ||
expect(removeLastHangulCharacter('일요일')).toBe('일요이'); | ||
expect(removeLastHangulCharacter('깎')).toBe('까'); | ||
}); | ||
it('빈 문자열일 경우 빈 문자열을 반환한다.', () => { | ||
expect(removeLastHangulCharacter('')).toBe(''); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters