From bc60f02f66f4f936157364158dce4cbd5bf01695 Mon Sep 17 00:00:00 2001 From: Torsten Date: Sun, 22 Mar 2020 17:47:31 +0200 Subject: [PATCH] remove risc tests from rubyx layer duplication, better ones in slot --- test/rubyx/macro/test_integer_comparison.rb | 5 +---- test/rubyx/macro/test_integer_div10.rb | 3 --- test/rubyx/macro/test_integer_div4.rb | 3 --- test/rubyx/macro/test_integer_operator.rb | 3 --- test/rubyx/macro/test_object_exit.rb | 3 --- test/rubyx/macro/test_object_get.rb | 3 --- test/rubyx/macro/test_object_init.rb | 3 --- test/rubyx/macro/test_object_missing.rb | 3 --- test/rubyx/macro/test_object_set.rb | 3 --- test/rubyx/macro/test_word_get.rb | 3 --- test/rubyx/macro/test_word_putstring.rb | 3 --- test/rubyx/macro/test_word_set.rb | 3 --- 12 files changed, 1 insertion(+), 37 deletions(-) diff --git a/test/rubyx/macro/test_integer_comparison.rb b/test/rubyx/macro/test_integer_comparison.rb index fd83ac83..2d0a4a3f 100644 --- a/test/rubyx/macro/test_integer_comparison.rb +++ b/test/rubyx/macro/test_integer_comparison.rb @@ -4,7 +4,7 @@ module RubyX module Macro class TestIntegerSame < MiniTest::Test include MacroHelper - def op ; :== ; end + def op ; :>= ; end # is == valid ?? def len ; 24 ; end def source < ; end diff --git a/test/rubyx/macro/test_integer_div10.rb b/test/rubyx/macro/test_integer_div10.rb index e48f7cce..e4591668 100644 --- a/test/rubyx/macro/test_integer_div10.rb +++ b/test/rubyx/macro/test_integer_div10.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::Div10 , compiler.slot_instructions.next.class end - def test_risc - assert_equal 70 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_integer_div4.rb b/test/rubyx/macro/test_integer_div4.rb index a4bf2127..3d78fcd5 100644 --- a/test/rubyx/macro/test_integer_div4.rb +++ b/test/rubyx/macro/test_integer_div4.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::Div4 , compiler.slot_instructions.next.class end - def test_risc - assert_equal 39 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_integer_operator.rb b/test/rubyx/macro/test_integer_operator.rb index c7fe1c89..49c49b09 100644 --- a/test/rubyx/macro/test_integer_operator.rb +++ b/test/rubyx/macro/test_integer_operator.rb @@ -24,9 +24,6 @@ GET assert_equal SlotMachine::IntOperator , compiler.slot_instructions.next.class assert_equal op , compiler.slot_instructions.next.operator end - def test_risc - assert_equal 40 , compiler.to_risc.risc_instructions.length - end end class TestIntegerMinus < TestIntegerPlus def op ; :- ; end diff --git a/test/rubyx/macro/test_object_exit.rb b/test/rubyx/macro/test_object_exit.rb index cda2d29f..f26f0b9c 100644 --- a/test/rubyx/macro/test_object_exit.rb +++ b/test/rubyx/macro/test_object_exit.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::Exit , compiler.slot_instructions.next.class end - def test_risc - assert_equal 38 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_object_get.rb b/test/rubyx/macro/test_object_get.rb index 28b6d11e..56f431e4 100644 --- a/test/rubyx/macro/test_object_get.rb +++ b/test/rubyx/macro/test_object_get.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::GetInternalWord , compiler.slot_instructions.next.class end - def test_risc - assert_equal 17 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_object_init.rb b/test/rubyx/macro/test_object_init.rb index ad720301..8c7b7bcf 100644 --- a/test/rubyx/macro/test_object_init.rb +++ b/test/rubyx/macro/test_object_init.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::Init , compiler.slot_instructions.next.class end - def test_risc - assert_equal 30 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_object_missing.rb b/test/rubyx/macro/test_object_missing.rb index c6895c85..f854ae5d 100644 --- a/test/rubyx/macro/test_object_missing.rb +++ b/test/rubyx/macro/test_object_missing.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::MethodMissing , compiler.slot_instructions.next.class end - def test_risc - assert_equal 15 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_object_set.rb b/test/rubyx/macro/test_object_set.rb index 3484f78f..7845a2de 100644 --- a/test/rubyx/macro/test_object_set.rb +++ b/test/rubyx/macro/test_object_set.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::SetInternalWord , compiler.slot_instructions.next.class end - def test_risc - assert_equal 19 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_word_get.rb b/test/rubyx/macro/test_word_get.rb index 0eb2b331..75ed0f2f 100644 --- a/test/rubyx/macro/test_word_get.rb +++ b/test/rubyx/macro/test_word_get.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::GetInternalByte , compiler.slot_instructions.next.class end - def test_risc - assert_equal 39 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_word_putstring.rb b/test/rubyx/macro/test_word_putstring.rb index 8827c638..1e0fe4fb 100644 --- a/test/rubyx/macro/test_word_putstring.rb +++ b/test/rubyx/macro/test_word_putstring.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::Putstring , compiler.slot_instructions.next.class end - def test_risc - assert_equal 42 , compiler.to_risc.risc_instructions.length - end end end end diff --git a/test/rubyx/macro/test_word_set.rb b/test/rubyx/macro/test_word_set.rb index d5759a1d..eb371538 100644 --- a/test/rubyx/macro/test_word_set.rb +++ b/test/rubyx/macro/test_word_set.rb @@ -22,9 +22,6 @@ GET def test_instr_get assert_equal SlotMachine::SetInternalByte , compiler.slot_instructions.next.class end - def test_risc - assert_equal 20 , compiler.to_risc.risc_instructions.length - end end end end