Sha256: 6d0ac287433287d2aa556f2b257d85fa0b253a6738ceb556ca71fba2726dfece

Contents?: true

Size: 1.37 KB

Versions: 31

Compression:

Stored size: 1.37 KB

Contents

Feature: Create Directory

  Use the `#create_directory`-method to create a directory within `aruba`'s
  working directory.

  ```ruby
  require 'spec_helper'

  RSpec.configure do |config|
    config.include Aruba::Api
  end

  RSpec.describe 'Create directory' do
    let(:directory) { 'dir.d' }
    before(:each) { create_directory(directory) }

    it { expect(directory).to be_an_existing_directory }
  end
  ```

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

  Scenario: New directory
    Given a file named "spec/create_directory_spec.rb" with:
    """ruby
    require 'spec_helper'

    RSpec.describe 'Create directory', :type => :aruba do
      let(:directory) { 'dir.d' }
      before(:each) { create_directory(directory) }

      it { expect(directory).to be_an_existing_directory }
    end
    """
    When I run `rspec`
    Then the specs should all pass

  Scenario: Existing directory

    It does not complain if a directory already exists.

    Given a file named "spec/create_directory_spec.rb" with:
    """ruby
    require 'spec_helper'

    RSpec.describe 'Create directory', :type => :aruba do
      let(:directory) { 'dir.d' }

      before(:each) { create_directory(directory) }
      before(:each) { create_directory(directory) }

      it { expect(directory).to be_an_existing_directory }
    end
    """
    When I run `rspec`
    Then the specs should all pass

Version data entries

31 entries across 31 versions & 2 rubygems

Version Path
aruba-0.14.14 features/04_aruba_api/filesystem/create_directory.feature
aruba-0.14.13 features/04_aruba_api/filesystem/create_directory.feature
aruba-0.14.12 features/04_aruba_api/filesystem/create_directory.feature
aruba-0.14.11 features/04_aruba_api/filesystem/create_directory.feature
aruba-0.14.10 features/04_aruba_api/filesystem/create_directory.feature
aruba-0.14.9 features/api/filesystem/create_directory.feature
aruba-0.14.8 features/api/filesystem/create_directory.feature
aruba-0.14.7 features/api/filesystem/create_directory.feature
aruba-0.14.6 features/api/filesystem/create_directory.feature
aruba-0.14.5 features/api/filesystem/create_directory.feature
aruba-0.14.4 features/api/filesystem/create_directory.feature
aruba-0.14.3 features/api/filesystem/create_directory.feature
aruba-win-fix-0.14.2 features/api/filesystem/create_directory.feature
aruba-0.14.2 features/api/filesystem/create_directory.feature
aruba-0.14.1 features/api/filesystem/create_directory.feature
aruba-0.14.0 features/api/filesystem/create_directory.feature
aruba-0.13.0 features/api/filesystem/create_directory.feature
aruba-0.12.0 features/api/filesystem/create_directory.feature
aruba-0.11.2 features/api/filesystem/create_directory.feature
aruba-0.11.1 features/api/filesystem/create_directory.feature