Sha256: 095b4f24aafb7e50ab66c07d0d8db39b710d85be3d890bb68bd942c928dea239
Contents?: true
Size: 607 Bytes
Versions: 1
Compression:
Stored size: 607 Bytes
Contents
require 'test/unit' require 'util/array_alternatives' class UTestArrayAlternatives < Test::Unit::TestCase def test_01_normal_use first, second, third = [1], [2], [3, 4] a = first / second / third alts = a.assemble_alternatives assert_kind_of(Array, alts) assert_equal(3, alts.length) assert_equal(first, alts[0]) assert_equal(second, alts[1]) assert_equal(third, alts[2]) end def test_02_without_any_alternatives a = [1] alts = a.assemble_alternatives assert_kind_of(Array, alts) assert_equal(1, alts.length) assert_equal(a, alts[0]) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rockit-0.7.1 | tests/unit/util/utest_array_alternatives.rb |