References
Category:Anti-war songs
Category:Canadian poems
Category:Canadian songs
Category:Canadian children's songs
Category:1980s ballads
Category:Anti-war poemsrequire_relative '../../spec_helper'
require_relative 'fixtures/classes'
describe "Array#shift" do
it "returns the first element" do
[1, 2, 3, 4, 5].shift.should == 1
[1, 2, 3, 4, 5].shift(1).should == 2
[1, 2, 3, 4, 5].shift(-1).should == 3
[1, 2, 3, 4, 5].shift(10).should == 4
[1, 2, 3, 4, 5].shift(100).should == 5
end
it "yields elements from the array to the block" do
al = []
[] do |x|
al be359ba680
Related links:
Comments