Add test for nearley include of unicode

This commit is contained in:
Kaspar Emanuel 2017-10-16 16:17:40 +01:00
parent b491138d9a
commit e05c62ca06
3 changed files with 8 additions and 1 deletions

View File

@ -0,0 +1,3 @@
@include "unicode.ne"
main -> x

View File

@ -1 +1 @@
main -> "±a"
x -> "±a"

View File

@ -73,6 +73,10 @@ class TestNearley(unittest.TestCase):
def test_utf8_2(self):
fn = os.path.join(TEST_PATH, 'grammars/unicode.ne')
nearley_tool_main(fn, 'x', NEARLEY_PATH)
def test_include_utf8(self):
fn = os.path.join(TEST_PATH, 'grammars/include_unicode.ne')
nearley_tool_main(fn, 'main', NEARLEY_PATH)