Sha256: ea7d40e063b959ab9625c4c011a0a2be20efb5db12abded50386dbc2a7b5ea08

Contents?: true

Size: 517 Bytes

Versions: 2

Compression:

Stored size: 517 Bytes

Contents

FactoryGirl.define do
  factory :node, :class => Bebox::Node do
    environment   'vagrant'
    project_root  "#{Dir.pwd}/tmp/bebox-pname"
    hostname      'node0.server1.test'
    ip            YAML.load_file('spec/support/config_specs.yaml')['test_ip']

    initialize_with { new(environment, project_root, hostname, ip) }

    trait :created do
      after(:build) do |node|
        node.create
      end
    end

    trait :removed do
      after(:build) do |node|
        node.remove
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
bebox-0.1.0 spec/factories/node.rb
bebox-0.0.1 spec/factories/node.rb