"""Tests for processing of SGF files.""" import unittest from imago.sgfParser.sgfyacc import parser TESTING_SGF = 'tests/testingSGF.sgf' class TestSGF(unittest.TestCase): """Test processing SGF files.""" def testToGameTree(self): """Test converting file to GameTree""" file = open(TESTING_SGF, "r") text = file.read() file.close() astNode = parser.parse(text) astNode.toGameMoveTree() astNode.toString() if __name__ == '__main__': unittest.main()