sgf-parsing: update tests to 1.2.0 (#1615)

* added not equal implementation

* added a test for multiple properties

* fixed linting errors

* update version
This commit is contained in:
elyashiv
2018-12-10 15:30:17 +02:00
committed by Corey McCandless
parent 313d1d163f
commit 88c5c61159
2 changed files with 12 additions and 1 deletions

View File

@@ -3,7 +3,7 @@ import unittest
from sgf_parsing import parse, SgfTree
# Tests adapted from `problem-specifications//canonical-data.json` @ v1.0.0
# Tests adapted from `problem-specifications//canonical-data.json` @ v1.2.0
class SgfParsingTest(unittest.TestCase):
def test_empty_input(self):
@@ -81,6 +81,14 @@ class SgfParsingTest(unittest.TestCase):
)
self.assertEqual(parse(input_string), expected)
def test_multiple_properties(self):
input_string = '(;A[b]C[d])'
expected = SgfTree(
properties={'A': ['b'],
'C': ['d']}
)
self.assertEqual(parse(input_string), expected)
# Utility functions
def setUp(self):
try: