Skip to content
This repository has been archived by the owner on Mar 8, 2018. It is now read-only.

Commit

Permalink
Add a full-stack integration test for blimpy start
Browse files Browse the repository at this point in the history
  • Loading branch information
R. Tyler Croy committed Apr 28, 2012
1 parent 2792e16 commit 153cdb6
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 16 deletions.
2 changes: 1 addition & 1 deletion Rakefile
Expand Up @@ -16,7 +16,7 @@ namespace :cucumber do
end

Cucumber::Rake::Task.new('integration') do |t|
t.cucumber_opts = cucumber_opts + '--tags @slow'
t.cucumber_opts = cucumber_opts + ' --tags @slow'
end
end

Expand Down
52 changes: 37 additions & 15 deletions features/cli/start.feature
Expand Up @@ -9,19 +9,41 @@ Feature: Start a VM or cluster of VMs in the cloud
"""
And the exit status should be 1

Scenario: With a simple Blimpfile
Given I have the Blimpfile:
"""
Blimpy.fleet do |f|
f.add do |host|
host.group = 'Simple'
host.name = 'Cucumber Host'
end
Scenario: dry-run start with a simple Blimpfile
Given I have the Blimpfile:
"""
Blimpy.fleet do |f|
f.add do |host|
host.group = 'Simple'
host.name = 'Cucumber Host'
end
end
"""
When I run `blimpy start --dry-run`
Then the exit status should be 0
And the output should contain:
"""
Up, up and away!
"""

@slow @destroy
Scenario: start with a functional Blimpfile
Given I have the Blimpfile:
"""
Blimpy.fleet do |f|
f.add do |host|
host.group = 'Simple'
host.name = 'Cucumber Host'
end
"""
When I run `blimpy start --dry-run`
Then the exit status should be 0
And the output should contain:
"""
Up, up and away!
"""
end
"""
When I run `blimpy start`
Then the exit status should be 0
And the output should contain:
"""
Up, up and away!
"""
And the output should contain:
"""
online at:
"""
10 changes: 10 additions & 0 deletions features/support/hooks.rb
Expand Up @@ -6,6 +6,16 @@
@dirs = [@tempdir]
end

Before '@slow' do
@aruba_timeout_seconds = 90
end

After '@destroy' do |scenario|
Dir.chdir(@tempdir) do
`blimpy destroy`
end
end

After do |scenario|
Dir.chdir(@cwd)

Expand Down

0 comments on commit 153cdb6

Please sign in to comment.