Sha256: 4d011458aae58cdbdf204a951b90167669fc54bbebc016edb4f3e944d2ed0a1b

Contents?: true

Size: 595 Bytes

Versions: 5

Compression:

Stored size: 595 Bytes

Contents

require 'spec_helper'

describe Heirloom::Catalog::List do

  before do
    @config_double = double 'config'
    @sdb_double = double 'sdb'
    Heirloom::AWS::SimpleDB.should_receive(:new).
                            with(:config => @config_double).
                            and_return @sdb_double
    @list = Heirloom::Catalog::List.new :config => @config_double
  end

  it "should list all heirlooms in the catalog" do
    @sdb_double.should_receive(:select).
                with("SELECT * FROM heirloom").
                and_return 'result'
    @list.all.should == 'result'
  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
heirloom-0.12.7 spec/catalog/list_spec.rb
heirloom-0.12.5 spec/catalog/list_spec.rb
heirloom-0.12.4 spec/catalog/list_spec.rb
heirloom-0.12.3 spec/catalog/list_spec.rb
heirloom-0.12.2 spec/catalog/list_spec.rb