name test classes correctly
This commit is contained in:
parent
fe799845aa
commit
4ec3211b61
4 changed files with 5 additions and 5 deletions
|
@ -5,8 +5,8 @@ require 'test/unit'
|
||||||
|
|
||||||
require_relative '../lib/core'
|
require_relative '../lib/core'
|
||||||
|
|
||||||
class TestParser < Test::Unit::TestCase
|
class TesttLanguageOperations < Test::Unit::TestCase
|
||||||
def test_plus
|
def test_add
|
||||||
stack = Rpn::Core::Operations.add [{ value: 1, type: :numeric },
|
stack = Rpn::Core::Operations.add [{ value: 1, type: :numeric },
|
||||||
{ value: 2, type: :numeric }]
|
{ value: 2, type: :numeric }]
|
||||||
assert_equal [{ value: 3, type: :numeric }],
|
assert_equal [{ value: 3, type: :numeric }],
|
||||||
|
|
|
@ -8,7 +8,7 @@ require_relative '../lib/dictionary'
|
||||||
require_relative '../lib/parser'
|
require_relative '../lib/parser'
|
||||||
require_relative '../lib/runner'
|
require_relative '../lib/runner'
|
||||||
|
|
||||||
class TestParser < Test::Unit::TestCase
|
class TestLanguageProgram < Test::Unit::TestCase
|
||||||
def test_eval
|
def test_eval
|
||||||
stack = Rpn::Core::Program.eval( [{ value: '« 2 dup * dup »', type: :program }], Rpn::Dictionary.new )
|
stack = Rpn::Core::Program.eval( [{ value: '« 2 dup * dup »', type: :program }], Rpn::Dictionary.new )
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ require 'test/unit'
|
||||||
|
|
||||||
require_relative '../lib/core'
|
require_relative '../lib/core'
|
||||||
|
|
||||||
class TestParser < Test::Unit::TestCase
|
class TestLanguageStack < Test::Unit::TestCase
|
||||||
def test_swap
|
def test_swap
|
||||||
stack = Rpn::Core::Stack.swap [{ value: 1, type: :numeric },
|
stack = Rpn::Core::Stack.swap [{ value: 1, type: :numeric },
|
||||||
{ value: 2, type: :numeric }]
|
{ value: 2, type: :numeric }]
|
||||||
|
|
|
@ -5,7 +5,7 @@ require 'test/unit'
|
||||||
|
|
||||||
require_relative '../lib/core'
|
require_relative '../lib/core'
|
||||||
|
|
||||||
class TestParser < Test::Unit::TestCase
|
class TestLanguageTimeDate < Test::Unit::TestCase
|
||||||
def test_time
|
def test_time
|
||||||
now = Time.now.to_s
|
now = Time.now.to_s
|
||||||
stack = Rpn::Core::TimeDate.time( [] )
|
stack = Rpn::Core::TimeDate.time( [] )
|
||||||
|
|
Loading…
Reference in a new issue