testgen 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
data/ChangeLog CHANGED
@@ -1,3 +1,6 @@
1
+ === Version 0.2.2 / 2011-09-30
2
+ * Created empty pages directory when pageobject driver provided
3
+
1
4
  === Version 0.2.1 / 2011-09-29
2
5
  * Fixed error in generated Rakefile
3
6
 
@@ -24,4 +24,8 @@ Feature: Adding support for the --pageobject-driver option
24
24
  Then a file named "sample/features/support/hooks.rb" should exist
25
25
  And the file "sample/features/support/hooks.rb" should contain "require 'selenium-webdriver'"
26
26
  And the file "sample/features/support/hooks.rb" should contain "@browser = Selenium::Webdriver.for :firefox"
27
-
27
+
28
+ Scenario: Creating the pages directory
29
+ When I run `testgen project sample --pageobject-driver=selenium`
30
+ Then a directory named "sample/features/support/pages" should exist
31
+
@@ -41,7 +41,17 @@ module TestGen
41
41
  end
42
42
 
43
43
  def copy_hooks
44
- template "hooks.rb.tt", "#{name}/features/support/hooks.rb" unless pageobject_driver.downcase == 'none'
44
+ template "hooks.rb.tt", "#{name}/features/support/hooks.rb" unless no_driver_selected
45
+ end
46
+
47
+ def create_pages_directory
48
+ empty_directory("#{name}/features/support/pages") unless no_driver_selected
49
+ end
50
+
51
+ private
52
+
53
+ def no_driver_selected
54
+ pageobject_driver.downcase == 'none'
45
55
  end
46
56
  end
47
57
  end
@@ -1,3 +1,3 @@
1
1
  module TestGen
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: testgen
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.2.1
5
+ version: 0.2.2
6
6
  platform: ruby
7
7
  authors:
8
8
  - Jeffrey S. Morgan