Sha256: 5dddd9d11da5a940f98f5e6026260a470a34b850e9dc0671c6c4bacd3789f7ee
Contents?: true
Size: 822 Bytes
Versions: 1
Compression:
Stored size: 822 Bytes
Contents
require File.expand_path(File.join(File.dirname(__FILE__), '..', '..', 'test_helper.rb')) class HashLiteralAssignmentTest < Test::Unit::TestCase include KoiReferenceParser test "assignment of empty hash literal" do tree = Parser.parse('test = {}') assert_assigns(HashLiteral, nil, tree) end test "assignment of hash literal with single key-value pair" do tree = Parser.parse('test = { 1 => 2 }') assert_assigns(HashLiteral, nil, tree) end test "assignment of hash literal with 2 key-value pairs" do tree = Parser.parse('test = { 1 => 2, 2 => 2 }') assert_assigns(HashLiteral, nil, tree) end test "assignment of hash literal with 3 key-value pairs" do tree = Parser.parse('test = { 1 => 2, 2 => 2, 3 => 2 }') assert_assigns(HashLiteral, nil, tree) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
koi-reference-parser-0.0.3 | test/unit/assignment/hash_literal_assignment_test.rb |