Skip to content

Commit

Permalink
put test words in test names
Browse files Browse the repository at this point in the history
  • Loading branch information
aqandrew committed Jan 24, 2024
1 parent f3e1694 commit 6b7bdd1
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions src/tokenizer.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,57 +11,57 @@ describe('tokenizer', () => {

describe('single word', () => {
describe('monosyllabic', () => {
test('lone vowel', () => {
test('lone vowel (o)', () => {
const tokens = tokenize('o');
expect(tokens).toEqual(['o']);
});

test('A vowel', () => {
test('A vowel (ba)', () => {
const tokens = tokenize('ba');
expect(tokens).toEqual(['ba']);
});

test('O vowel', () => {
test('O vowel (mo)', () => {
const tokens = tokenize('mo');
expect(tokens).toEqual(['mo']);
});

test('U vowel', () => {
test('U vowel (uy)', () => {
const tokens = tokenize('uy');
expect(tokens).toEqual(['u', 'y']);
});

test('I vowel', () => {
test('I vowel (si)', () => {
const tokens = tokenize('si');
expect(tokens).toEqual(['si']);
});

test('E vowel', () => {
test('E vowel (ke)', () => {
const tokens = tokenize('ke');
expect(tokens).toEqual(['ke']);
});

test('initial vowel + final consonant', () => {
test('initial vowel + final consonant (ay)', () => {
const tokens = tokenize('ay');
expect(tokens).toEqual(['a', 'y']);
});

test('initial consnant + final consonant', () => {
test('initial consnant + final consonant (daw)', () => {
const tokens = tokenize('daw');
expect(tokens).toEqual(['da', 'w']);
});

test('initial digraph', () => {
test('initial digraph (nga)', () => {
const tokens = tokenize('nga');
expect(tokens).toEqual(['nga']);
});

test('initial vowel + final digraph', () => {
test('initial vowel + final digraph (ang)', () => {
const tokens = tokenize('ang');
expect(tokens).toEqual(['a', 'ng']);
});

test('initial consonant + final digraph', () => {
test('initial consonant + final digraph (lang)', () => {
const tokens = tokenize('lang');
expect(tokens).toEqual(['la', 'ng']);
});
Expand All @@ -78,32 +78,32 @@ describe('tokenizer', () => {
});

describe('multisyllabic', () => {
test('vowels only', () => {
test('vowels only (oo)', () => {
const tokens = tokenize('oo');
expect(tokens).toEqual(['o', 'o']);
});

test('syllables with A vowels only', () => {
test('syllables with A vowels only (talaga)', () => {
const tokens = tokenize('talaga');
expect(tokens).toEqual(['ta', 'la', 'ga']);
});

test('initial consonant syllable followed by initial vowel syllable', () => {
test('initial consonant syllable followed by initial vowel syllable (laruin)', () => {
const tokens = tokenize('laruin');
expect(tokens).toEqual(['la', 'ru', 'i', 'n']);
});

test('initial digraph x2', () => {
test('initial digraph x2 (nganga)', () => {
const tokens = tokenize('nganga');
expect(tokens).toEqual(['nga', 'nga']);
});

test('nga in middle of word', () => {
test('nga in middle of word (tulungan)', () => {
const tokens = tokenize('tulungan');
expect(tokens).toEqual(['tu', 'lu', 'nga', 'n']);
});

test('ngi in middle of word', () => {
test('ngi in middle of word (hangin)', () => {
const tokens = tokenize('hangin');
expect(tokens).toEqual(['ha', 'ngi', 'n']);
});
Expand All @@ -112,12 +112,12 @@ describe('tokenizer', () => {

describe.skip('multiple words');

test('single punctuation', () => {
test('single punctuation (hinirang,)', () => {
const tokens = tokenize('hinirang,');
expect(tokens).toEqual(['hi', 'ni', 'ra', 'ng', ',']);
});

test('double punctuation', () => {
test('double punctuation (buhay.)', () => {
const tokens = tokenize('buhay.');
expect(tokens).toEqual(['bu', 'ha', 'y', '.']);
});
Expand Down

0 comments on commit 6b7bdd1

Please sign in to comment.