incubator-deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mfoj...@apache.org
Subject svn commit: r991480 - in /incubator/deltacloud/trunk/tests: ec2/99_rake.feature ec2/step_definitions/rake_steps.rb mock/99_rake.feature mock/step_definitions/rake_steps.rb
Date Wed, 01 Sep 2010 08:52:00 GMT
Author: mfojtik
Date: Wed Sep  1 08:51:59 2010
New Revision: 991480

URL: http://svn.apache.org/viewvc?rev=991480&view=rev
Log:
Fixed Cucumber features for Rake (rev 2)

Modified:
    incubator/deltacloud/trunk/tests/ec2/99_rake.feature
    incubator/deltacloud/trunk/tests/ec2/step_definitions/rake_steps.rb
    incubator/deltacloud/trunk/tests/mock/99_rake.feature
    incubator/deltacloud/trunk/tests/mock/step_definitions/rake_steps.rb

Modified: incubator/deltacloud/trunk/tests/ec2/99_rake.feature
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/tests/ec2/99_rake.feature?rev=991480&r1=991479&r2=991480&view=diff
==============================================================================
--- incubator/deltacloud/trunk/tests/ec2/99_rake.feature (original)
+++ incubator/deltacloud/trunk/tests/ec2/99_rake.feature Wed Sep  1 08:51:59 2010
@@ -3,5 +3,5 @@ Feature: Running rake tasks
   Scenario: I want to build Deltacloud API gem
     Given I have a clean /pkg directory
     When I run a 'package' task
-    Then I should see a gem file inside pkg directory
-    And I should see a tgz file inside pkg directory
+    Then I should see a 2 gem file inside pkg directory
+    And I should see a 1 tgz file inside pkg directory

Modified: incubator/deltacloud/trunk/tests/ec2/step_definitions/rake_steps.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/tests/ec2/step_definitions/rake_steps.rb?rev=991480&r1=991479&r2=991480&view=diff
==============================================================================
--- incubator/deltacloud/trunk/tests/ec2/step_definitions/rake_steps.rb (original)
+++ incubator/deltacloud/trunk/tests/ec2/step_definitions/rake_steps.rb Wed Sep  1 08:51:59
2010
@@ -14,6 +14,6 @@ When /^I run a '(\w+)' task$/ do |task|
  @task.invoke
 end
 
-Then /^I should see a (\w+) file inside (\w+) directory$/ do |ext, dir|
-  Dir["#{dir}/deltacloud-*.#{ext}"].size.should == 2
+Then /^I should see a (\d+) (\w+) file inside (\w+) directory$/ do |count, ext, dir|
+  Dir["#{dir}/deltacloud-*.#{ext}"].size.should == count.to_i
 end

Modified: incubator/deltacloud/trunk/tests/mock/99_rake.feature
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/tests/mock/99_rake.feature?rev=991480&r1=991479&r2=991480&view=diff
==============================================================================
--- incubator/deltacloud/trunk/tests/mock/99_rake.feature (original)
+++ incubator/deltacloud/trunk/tests/mock/99_rake.feature Wed Sep  1 08:51:59 2010
@@ -3,5 +3,5 @@ Feature: Running rake tasks
   Scenario: I want to build Deltacloud API gem
     Given I have a clean /pkg directory
     When I run a 'package' task
-    Then I should see a gem file inside pkg directory
-    And I should see a tgz file inside pkg directory
+    Then I should see a 2 gem file inside pkg directory
+    And I should see a 1 tgz file inside pkg directory

Modified: incubator/deltacloud/trunk/tests/mock/step_definitions/rake_steps.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/tests/mock/step_definitions/rake_steps.rb?rev=991480&r1=991479&r2=991480&view=diff
==============================================================================
--- incubator/deltacloud/trunk/tests/mock/step_definitions/rake_steps.rb (original)
+++ incubator/deltacloud/trunk/tests/mock/step_definitions/rake_steps.rb Wed Sep  1 08:51:59
2010
@@ -2,10 +2,6 @@ require 'fileutils'
 require 'rake'
 require 'find'
 
-Given /^I have a clean (.+) directory$/ do |dir|
-  FileUtils.rm_rf dir  
-end
-
 When /^I run a '(\w+)' task$/ do |task|
   @rake = Rake::Application.new
  Rake.application = @rake
@@ -14,6 +10,10 @@ When /^I run a '(\w+)' task$/ do |task|
  @task.invoke
 end
 
-Then /^I should see a (\w+) file inside (\w+) directory$/ do |ext, dir|
-  Dir["#{dir}/deltacloud-*.#{ext}"].size.should == 2
+Given /^I have a clean (.+) directory$/ do |dir|
+  FileUtils.rm_rf dir  
+end
+
+Then /^I should see a (\d+) (\w+) file inside (\w+) directory$/ do |count, ext, dir|
+  Dir["#{dir}/deltacloud-*.#{ext}"].size.should == count.to_i
 end



Mime
View raw message