Exemple #1
0
 def test_defaults(self):
     phonemes()
Exemple #2
0
 def test_defaults_not_empty(self):
     vcs = phonemes()
     self.assertTrue(all([ps for ps in vcs]))
Exemple #3
0
 def test_too_many_cons(self):
     nv = 4
     nc = 400
     vs, cs = phonemes((nv,nv), (nc,nc))
     self.assertTrue(len(cs) < nc)
Exemple #4
0
 def test_no_cons(self):
     nv = 4
     nc = 0
     vs, cs = phonemes((nv,nv), (nc,nc))
     self.assertEqual(len(cs), 0)
Exemple #5
0
 def test_too_many_vowels(self):
     nv = 100
     nc = 10
     vs, cs = phonemes((nv,nv), (nc,nc))
     self.assertTrue(len(vs) < nv)
Exemple #6
0
 def test_no_vowels(self):
     nv = 0
     nc = 10
     vs, cs = phonemes((nv,nv), (nc,nc))
     self.assertEqual(len(vs), 0)
Exemple #7
0
 def test_hard_limits(self):
     nv = 3
     nc = 10
     vs, cs = phonemes((nv,nv), (nc,nc))
     self.assertEqual(len(vs), nv)
     self.assertEqual(len(cs), nc)