Ejemplo n.º 1
0
    def test_hapax_legomenon( self ):

        ideal = [ 'and', 'valleys', 'over', 'it', 'greenest', 'seraph', 'our', 'its', 'stood', 'stately', 'there', 'spread', 'monarch', 'angels', 'head', 'good',
            'never', 'half', 'by', 'fabric', 'a', 'reared', 'of', 'radiant', 'tenanted', 'thought', 's', 'so', 'dominion', 'pinion', 'once' ]
        hapax_legomenons = exercises.find_hapax_legomenons( 'data/usher.md' )

        self.assertEqual( set(ideal), hapax_legomenons )
Ejemplo n.º 2
0
    def test_hapax_legomenon( self ):

        ideal = [ 'and', 'valleys', 'over', 'it', 'greenest', 'seraph', 'our', 'its', 'stood', 'stately', 'there', 'spread', 'monarch', 'angels', 'head', 'good',
            'never', 'half', 'by', 'fabric', 'a', 'reared', 'of', 'radiant', 'tenanted', 'thought', 's', 'so', 'dominion', 'pinion', 'once' ]
        hapax_legomenons = exercises.find_hapax_legomenons( 'data/usher.md' )

        self.assertEqual( ideal, hapax_legomenons )