Sha256: d37a20f850c718e4c2f98682918e705662b27974a72ddc937d3f9132fc288849

Contents?: true

Size: 816 Bytes

Versions: 2

Compression:

Stored size: 816 Bytes

Contents

require "integration/test_helper"

describe "Listing containers" do
  after do
    ContainerNameHelper.clean
  end

  it "returns an empty list if there are no containers" do
    all_containers = Azure::Blobs.containers
    all_containers.must_be_empty
  end

  it "returns a list of containers if one or more exist" do
    container_1 = Azure::Blobs.create_container(ContainerNameHelper.name)
    container_2 = Azure::Blobs.create_container(ContainerNameHelper.name)

    all_containers = Azure::Blobs.containers
    all_containers.must_include(container_1)
    all_containers.must_include(container_2)
  end

  it "loads the properties of each container" do
    Azure::Blobs.create_container(ContainerNameHelper.name)
    container = Azure::Blobs.containers.first

    container.properties.wont_be_empty
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
azure-0.1.1 test/integration/blobs/list_containers_test.rb
azure-0.1.0 test/integration/blobs/list_containers_test.rb