Sha256: c69a15e79f24a6b8514de7b6f9258e154697b97eb8cb0c5ff91c94afa2fc4247

Contents?: true

Size: 510 Bytes

Versions: 10

Compression:

Stored size: 510 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper')

require 'hamster/list'

describe Hamster::List do

  [:dup, :clone].each do |method|

    [
      [],
      ["A"],
      ["A", "B", "C"],
    ].each do |values|

      describe "on #{values.inspect}" do

        before do
          @original = Hamster.list(*values)
          @result = @original.send(method)
        end

        it "returns self" do
          @result.should equal(@original)
        end

      end

    end

  end

end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
hamster-0.2.5 spec/hamster/list/copying_spec.rb
hamster-0.2.4 spec/hamster/list/copying_spec.rb
hamster-0.2.3 spec/hamster/list/copying_spec.rb
hamster-0.2.2 spec/hamster/list/copying_spec.rb
hamster-0.2.1 spec/hamster/list/copying_spec.rb
hamster-0.2.0 spec/hamster/list/copying_spec.rb
hamster-0.1.23 spec/hamster/list/copying_spec.rb
hamster-0.1.22 spec/hamster/list/copying_spec.rb
hamster-0.1.21 spec/hamster/list/copying_spec.rb
hamster-0.1.20 spec/hamster/list/copying_spec.rb