Exemple #1
0
    def testOffsetAbsoluteRefs(self):
        node = FLRowReferenceParseNode(['_$3 '])
        node.offset(0xDEADBEEF, 54)
        self.assertEquals(node.localReference, '_$3 ')

        node.offset(0xDEADBEEF, 4, moveAbsolute=True)
        self.assertEquals(node.localReference, '_$7 ')
    def testOffsetAbsoluteRefs(self):
        node = FLRowReferenceParseNode(['_$3 '])
        node.offset(0xDEADBEEF, 54)
        self.assertEquals(node.localReference, '_$3 ')

        node.offset(0xDEADBEEF, 4, moveAbsolute=True)
        self.assertEquals(node.localReference, '_$7 ')
 def testOffset(self):
     node = FLRowReferenceParseNode(['_2 '])
     node.offset(1000, 0)
     self.assertEquals(node.localReference, '_2 ')
     node.offset(-1000, 1)
     self.assertEquals(node.localReference, '_3 ')
     node.offset(0, -2)
     self.assertEquals(node.localReference, '_1 ')
     node.offset(1337, -1)
     self.assertEquals(node.localReference, '#Invalid! ')
Exemple #4
0
 def testOffset(self):
     node = FLRowReferenceParseNode(['_2 '])
     node.offset(1000, 0)
     self.assertEquals(node.localReference, '_2 ')
     node.offset(-1000, 1)
     self.assertEquals(node.localReference, '_3 ')
     node.offset(0, -2)
     self.assertEquals(node.localReference, '_1 ')
     node.offset(1337, -1)
     self.assertEquals(node.localReference, '#Invalid! ')