plint

French poetry validator
git clone https://a3nm.net/git/plint/
Log | Files | Refs | README

commit 193df14ab9716707b775c0b39ac504ad777ca94b
parent 484c48a9b590a86af96c1c7d32d17ba4159c6a44
Author: Antoine Amarilli <a3nm@a3nm.net>
Date:   Sun, 27 Jul 2014 14:57:31 +0200

load diaeresis to repair versetest

Diffstat:
versetest.py | 8++++++++
1 file changed, 8 insertions(+), 0 deletions(-)

diff --git a/versetest.py b/versetest.py @@ -1,6 +1,7 @@ #!/usr/bin/python3 import template +import diaeresis import verse import unittest from pprint import pprint @@ -122,6 +123,12 @@ class SimpleCounts(Counts): self.assertEqual(1, len(f)) self.assertEqual(self.getWeight(f[0]), 4) +class ExceptionCounts(Counts): + def testPays(self): + f = self.runCount("pays abbaye alcoyle", limit=8) + self.assertEqual(1, len(f)) + self.assertEqual(self.getWeight(f[0]), 8) + class AspiratedCounts(Counts): def testBaudelaire1half(self): possible = self.runCount("funeste hélas", limit=4) @@ -178,5 +185,6 @@ class PoemCounts(Counts): self.assertTrue(self.achievesPossibility(possible, 12)) if __name__ == "__main__": + diaeresis.load_diaeresis('diaeresis.json') unittest.main()