Skip to content

Commit

Permalink
Created the unit test test_grammarHasIndirectFactorsStoSorEpsilon
Browse files Browse the repository at this point in the history
  • Loading branch information
evandrocoan committed Jul 8, 2018
1 parent d676f0c commit f84c8e9
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions source/unit_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,14 @@ def test_grammarIsInfiniteStoSorEpsilon(self):

self.assertTrue( firstGrammar.is_infinite() )

def test_grammarHasIndirectFactorsStoSorEpsilon(self):
firstGrammar = ChomskyGrammar.load_from_text_lines( wrap_text(
r"""
S -> aS | &
""" ) )

self.assertFalse( firstGrammar.has_indirect_factors() )


class TestGrammarFactoringAndRecursionSymbols(TestingUtilities):

Expand Down

0 comments on commit f84c8e9

Please sign in to comment.