rubyx/test/risc/position/test_code_position.rb
Torsten Ruger 4b33d1c056 fix many a test especially whole mom
but some positioning bug still in there preventing
binary to work
2018-07-02 17:01:07 +03:00

24 lines
685 B
Ruby

require_relative "helper"
module Risc
class TestPositionTranslated < MiniTest::Test
def setup
Parfait.boot!
@binary = Parfait::BinaryCode.new(1)
@method = Parfait.object_space.types.values.first.methods
@label = Risc.label("hi","ho")
end
def test_bin_propagates_existing
@binary.extend_to(16)
CodeListener.init( @binary , :interpreter).set(0)
assert_equal @binary.padded_length , Position.get(@binary.next).at
end
def test_bin_propagates_after
CodeListener.init( @binary , :interpreter).set(0)
@binary.extend_to(16)
assert_equal @binary.padded_length , Position.get(@binary.next).at
end
end
end