def testNoEncoding(self):
    path = os.path.join(os.path.dirname(__file__), 'teststreams.input1')
    stream = antlr3.FileStream(path)
    stream.seek(4)
    marker1 = stream.mark()
    stream.consume()
    marker2 = stream.mark()
    stream.consume()
    marker3 = stream.mark()
    stream.rewind(marker2)
    self.failUnlessEqual(stream.markDepth, 1)
    self.failUnlessEqual(stream.index(), 5)
    self.failUnlessEqual(stream.line, 2)
    self.failUnlessEqual(stream.charPositionInLine, 1)
    self.failUnlessEqual(stream.LA(1), 'a')
def testNoEncoding(self):
    path = os.path.join(os.path.dirname(__file__), 'teststreams.input1')
    stream = antlr3.FileStream(path)
    stream.seek(4)
    marker1 = stream.mark()
    stream.consume()
    marker2 = stream.mark()
    stream.consume()
    marker3 = stream.mark()
    stream.rewind(marker2)
    self.failUnlessEqual(stream.markDepth, 1)
    self.failUnlessEqual(stream.index(), 5)
    self.failUnlessEqual(stream.line, 2)
    self.failUnlessEqual(stream.charPositionInLine, 1)
    self.failUnlessEqual(stream.LA(1), 'a')