Sha256: 56dd04eac5e72bb1d98b839903491a449a69b57a2db8633317ea617d594b91ea

Contents?: true

Size: 605 Bytes

Versions: 40

Compression:

Stored size: 605 Bytes

Contents

require_relative "../../../spec_helper"
require "kontena/cli/stacks/list_command"

describe Kontena::Cli::Stacks::ListCommand do

  include ClientHelpers

  describe '#execute' do
    it 'requires api url' do
      expect(subject.class.requires_current_master).to be_truthy
    end

    it 'requires token' do
      expect(subject.class.requires_current_master_token).to be_truthy
    end

    it 'fetches stacks from master' do
      stacks = {
        'stacks' => []
      }
      expect(client).to receive(:get).with('grids/test-grid/stacks').and_return(stacks)
      subject.run([])
    end
  end
end

Version data entries

40 entries across 40 versions & 1 rubygems

Version Path
kontena-cli-1.1.6 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.5 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.5.rc3 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.5.rc2 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.5.rc1 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.4 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.3 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.2 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.2.rc2 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.2.rc1 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.1 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.1.rc1 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.0 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.0.rc2 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.0.rc1 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.1.0.pre1 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.0.6 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.0.6.rc1 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.0.5 spec/kontena/cli/stacks/list_command_spec.rb
kontena-cli-1.0.5.rc1 spec/kontena/cli/stacks/list_command_spec.rb