コード例 #1
0
 def test_book_line(self):
     """ Tests a text with book and line citations
     """
     text = NautilusDummy.getTextualNode(
         'urn:cts:latinLit:phi1020.phi001.perseus-lat2')
     self.assertEqual(scheme_grouper(text, text.getReffs),
                      level_grouper(text, text.getReffs, 2, 30))
コード例 #2
0
 def test_with_line(self):
     """ Tests a text with line citations mixed with something else
     """
     text = NautilusDummy.getTextualNode(
         'urn:cts:latinLit:phi0690.phi003.perseus-lat2')
     self.assertEqual(scheme_grouper(text, text.getReffs),
                      level_grouper(text, text.getReffs, 2, 30))
コード例 #3
0
 def test_special(self):
     """ Tests rules for specific texts
     """
     text = NautilusDummy.getTextualNode(
         'urn:cts:latinLit:stoa0040.stoa062.opp-lat1')
     self.assertEqual(scheme_grouper(text, text.getReffs),
                      level_grouper(text, text.getReffs, 1, 2))
コード例 #4
0
 def test_chapter_verse(self):
     """ Tests a text with chapter and verse citations
     """
     text = NautilusDummy.getTextualNode(
         'urn:cts:ancJewLit:hebBible.leviticus.leningrad-pntd')
     self.assertEqual(scheme_grouper(text, text.getReffs),
                      level_grouper(text, text.getReffs, 2, 1))
コード例 #5
0
 def test_chapter_mishnah(self):
     """ Tests a text with chapter and mishnah citations
     """
     text = NautilusDummy.getTextualNode(
         'urn:cts:ancJewLit:mishnah.arakhin.p179204')
     self.assertEqual(scheme_grouper(text, text.getReffs),
                      level_grouper(text, text.getReffs, 2, 1))
コード例 #6
0
 def test_chapter_section(self):
     """ Tests a text with chapter and section citations
     """
     text = NautilusDummy.getTextualNode(
         'urn:cts:latinLit:stoa0275.stoa027.perseus-lat2')
     self.assertEqual(scheme_grouper(text, text.getReffs),
                      level_grouper(text, text.getReffs, 2, 2))
コード例 #7
0
 def test_book(self):
     """ Tests a text with book citations
     """
     text = NautilusDummy.getTextualNode(
         'urn:cts:latinLit:stoa0149b.stoa006.opp-lat1')
     self.assertEqual(scheme_grouper(text, text.getReffs),
                      level_grouper(text, text.getReffs, 1, 1))
コード例 #8
0
 def test_book_chapter(self):
     """ Tests a text with book and chapter citations
     """
     text = NautilusDummy.getTextualNode(
         'urn:cts:latinLit:phi1351.phi004.perseus-lat2')
     self.assertEqual(scheme_grouper(text, text.getReffs),
                      level_grouper(text, text.getReffs, 2, 1))