[rspec-users] Someone please name this matcher for me

Matt Wynne lists at ruby-forum.com
Wed Aug 6 14:59:34 EDT 2008


How about
[1, 2, 3, 4, 1].should contain([1, 3, 1, 4, 2])

[1, 2, 3, 4, 1].should contain_only([1, 3, 1, 4, 2])


or (riffing off Zach)

[1, 2, 3, 4, 1].should be_composed_from([1, 3, 1, 4, 2])

Matt
-- 
Posted via http://www.ruby-forum.com/.


More information about the rspec-users mailing list