Sha256: 66afebadf1c14abaa4cfe3b7c7d7608f3d00bb1dafa8f0775eeb3266a8ae436f

Contents?: true

Size: 1.44 KB

Versions: 16

Compression:

Stored size: 1.44 KB

Contents

Feature: Return last command started

  Background:
    Given I use a fixture named "cli-app"

  Scenario: A command has been started
    Given a file named "spec/run_spec.rb" with:
    """ruby
    require 'spec_helper'

    RSpec.describe 'Run command', :type => :aruba do
      before(:each) { run('echo hello') }
      before(:each) { stop_all_commands }

      it { expect(last_command_started).to be_successfully_executed }
      it { expect(last_command_started.commandline).to eq 'echo hello' }
    end
    """
    When I run `rspec`
    Then the specs should all pass

  Scenario: Multiple commands have been started
    Given a file named "spec/run_spec.rb" with:
    """ruby
    require 'spec_helper'

    RSpec.describe 'Run command', :type => :aruba do
      before(:each) { run('echo hello') }
      before(:each) { run('echo world') }

      before(:each) { stop_all_commands }

      it { expect(last_command_started).to be_successfully_executed }
      it { expect(last_command_started.commandline).to eq 'echo world' }
    end
    """
    When I run `rspec`
    Then the specs should all pass

  Scenario: No command has been started
    Given a file named "spec/run_spec.rb" with:
    """ruby
    require 'spec_helper'

    RSpec.describe 'Run command', :type => :aruba do
      it { expect{ last_command_started.commandline }.to raise_error Aruba::NoCommandHasBeenStartedError }
    end
    """
    When I run `rspec`
    Then the specs should all pass

Version data entries

16 entries across 16 versions & 2 rubygems

Version Path
aruba-0.14.7 features/api/command/last_command_started.feature
aruba-0.14.6 features/api/command/last_command_started.feature
aruba-0.14.5 features/api/command/last_command_started.feature
aruba-0.14.4 features/api/command/last_command_started.feature
aruba-0.14.3 features/api/command/last_command_started.feature
aruba-win-fix-0.14.2 features/api/command/last_command_started.feature
aruba-0.14.2 features/api/command/last_command_started.feature
aruba-0.14.1 features/api/command/last_command_started.feature
aruba-0.14.0 features/api/command/last_command_started.feature
aruba-0.13.0 features/api/command/last_command_started.feature
aruba-0.12.0 features/api/command/last_command_started.feature
aruba-0.11.2 features/api/command/last_command_started.feature
aruba-0.11.1 features/api/command/last_command_started.feature
aruba-0.11.0.pre4 features/api/command/last_command_started.feature
aruba-0.11.0.pre3 features/api/command/last_command_started.feature
aruba-0.11.0.pre2 features/api/command/last_command_started.feature