1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/test/rubygems/test_gem_resolver_requirement_list.rb

21 lines
375 B
Ruby
Raw Normal View History

# frozen_string_literal: true
require 'rubygems/test_case'
class TestGemResolverRequirementList < Gem::TestCase
def setup
super
@list = Gem::Resolver::RequirementList.new
end
def test_each
dep = Gem::Dependency.new "a", "= 1"
req = Gem::Resolver::DependencyRequest.new(dep, nil)
@list.add req
assert_equal [req], @list.each.to_a
end
end