start of an idea

This commit is contained in:
Torsten Ruger 2015-07-02 10:44:44 +03:00
parent 9ca5ddf7c0
commit 185f4b4697

View File

@ -2,6 +2,12 @@ require_relative '../helper'
require 'parslet/convenience' require 'parslet/convenience'
require "yaml" require "yaml"
Parfait::Object.class_eval do
def secret_layout_hammer
internal_object_set(Parfait::Object::LAYOUT_INDEX , nil)
end
end
module VirtualHelper module VirtualHelper
# need a code generator, for arm # need a code generator, for arm
def setup def setup
@ -15,6 +21,8 @@ module VirtualHelper
# stops the whole objectspace beeing tested # stops the whole objectspace beeing tested
# with the class comes superclass and all methods # with the class comes superclass and all methods
expressions.first.instance_variable_set :@for_class , nil expressions.first.instance_variable_set :@for_class , nil
expressions.first.secret_layout_hammer
expressions.first.code.secret_layout_hammer
end end
if( expressions.first.is_a? Virtual::Self ) if( expressions.first.is_a? Virtual::Self )
# stops the whole objectspace beeing tested # stops the whole objectspace beeing tested
@ -22,7 +30,7 @@ module VirtualHelper
expressions.first.type.instance_variable_set :@of_class , nil expressions.first.type.instance_variable_set :@of_class , nil
end end
is = Sof.write(expressions) is = Sof.write(expressions)
#puts is puts is
is.gsub!("\n" , "*^*") is.gsub!("\n" , "*^*")
assert_equal @output , is assert_equal @output , is
end end