blob: 8497ce826229da787faa40ff88ae4ae5dffd02e4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
require_relative '../../spec_helper'
require_relative 'fixtures/classes'
require_relative 'shared/concat'
describe "String#<<" do
it_behaves_like :string_concat, :<<
it_behaves_like :string_concat_encoding, :<<
it_behaves_like :string_concat_type_coercion, :<<
it "raises an ArgumentError when given the incorrect number of arguments" do
-> { "hello".send(:<<) }.should raise_error(ArgumentError)
-> { "hello".send(:<<, "one", "two") }.should raise_error(ArgumentError)
end
end
|