|
1 |
| -import { myPackage } from '../src'; |
| 1 | +import { Script, translate } from '../src'; |
2 | 2 |
|
3 |
| -describe('index', () => { |
4 |
| - describe('myPackage', () => { |
5 |
| - it('should return a string containing the message', () => { |
6 |
| - const message = 'Hello'; |
| 3 | +describe('baybayin', () => { |
| 4 | + describe('translate', () => { |
| 5 | + it('should return a string containing the baybayin text', () => { |
| 6 | + const text = 'a'; |
7 | 7 |
|
8 |
| - const result = myPackage(message); |
| 8 | + const result = translate(text); |
9 | 9 |
|
10 |
| - expect(result).toMatch(message); |
| 10 | + expect(result).toMatch('\u1700'); |
| 11 | + }); |
| 12 | + }); |
| 13 | +}); |
| 14 | + |
| 15 | +describe('hanunoo', () => { |
| 16 | + describe('translate', () => { |
| 17 | + it('should return a string containing the hanunoo text', () => { |
| 18 | + const text = 'a'; |
| 19 | + |
| 20 | + const result = translate(text, Script.HANUNOO); |
| 21 | + |
| 22 | + expect(result).toMatch('\u1720'); |
| 23 | + }); |
| 24 | + }); |
| 25 | +}); |
| 26 | + |
| 27 | +describe('buhid', () => { |
| 28 | + describe('translate', () => { |
| 29 | + it('should return a string containing the buhid text', () => { |
| 30 | + const text = 'nga'; |
| 31 | + |
| 32 | + const result = translate(text, Script.BUHID); |
| 33 | + |
| 34 | + expect(result).toMatch('\u1745'); |
| 35 | + }); |
| 36 | + }); |
| 37 | +}); |
| 38 | + |
| 39 | +describe('tagbanwa', () => { |
| 40 | + describe('translate', () => { |
| 41 | + it('should return a string containing the tagbanwa text', () => { |
| 42 | + const text = 'nga'; |
| 43 | + |
| 44 | + const result = translate(text, Script.TAGBANWA); |
| 45 | + |
| 46 | + expect(result).toMatch('\u1765'); |
11 | 47 | });
|
12 | 48 | });
|
13 | 49 | });
|
0 commit comments