technicalpickles-jeweler 0.11.0 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/.gitignore +7 -0
- data/ChangeLog.markdown +8 -0
- data/README.markdown +9 -9
- data/ROADMAP +12 -0
- data/Rakefile +22 -5
- data/VERSION.yml +2 -2
- data/features/generator/cucumber.feature +83 -0
- data/features/generator/directory_layout.feature +76 -0
- data/features/generator/dotdocument.feature +14 -0
- data/features/generator/env_options.feature +9 -0
- data/features/generator/git.feature +94 -0
- data/features/generator/license.feature +11 -0
- data/features/generator/rakefile.feature +110 -0
- data/features/generator/readme.feature +12 -0
- data/features/generator/test.feature +41 -0
- data/features/generator/test_helper.feature +49 -0
- data/features/placeholder.feature +5 -0
- data/features/step_definitions/debug_steps.rb +6 -0
- data/features/step_definitions/filesystem_steps.rb +65 -0
- data/features/step_definitions/generator_steps.rb +251 -0
- data/features/step_definitions/task_steps.rb +6 -0
- data/features/support/env.rb +19 -0
- data/features/tasks/build_gem.feature +9 -0
- data/features/tasks/version.feature +24 -0
- data/features/tasks/version_bumping.feature +33 -0
- data/jeweler.gemspec +204 -0
- data/lib/jeweler/commands/release.rb +35 -11
- data/lib/jeweler/commands/version/base.rb +1 -1
- data/lib/jeweler/gemspec_helper.rb +4 -6
- data/lib/jeweler/generator/application.rb +8 -3
- data/lib/jeweler/generator/bacon_mixin.rb +39 -0
- data/lib/jeweler/generator/micronaut_mixin.rb +38 -0
- data/lib/jeweler/generator/minitest_mixin.rb +39 -0
- data/lib/jeweler/generator/options.rb +5 -1
- data/lib/jeweler/generator/rspec_mixin.rb +39 -0
- data/lib/jeweler/generator/shoulda_mixin.rb +39 -0
- data/lib/jeweler/generator/testunit_mixin.rb +39 -0
- data/lib/jeweler/generator.rb +48 -111
- data/lib/jeweler/rubyforge_tasks.rb +46 -0
- data/lib/jeweler/specification.rb +3 -2
- data/lib/jeweler/tasks.rb +32 -26
- data/lib/jeweler/templates/README.rdoc +1 -1
- data/lib/jeweler/templates/Rakefile +29 -52
- data/lib/jeweler/templates/bacon/helper.rb +1 -1
- data/lib/jeweler/templates/features/support/env.rb +4 -7
- data/lib/jeweler/templates/micronaut/helper.rb +1 -1
- data/lib/jeweler/templates/minitest/helper.rb +1 -1
- data/lib/jeweler/templates/rspec/flunking.rb +1 -1
- data/lib/jeweler/templates/rspec/helper.rb +1 -1
- data/lib/jeweler/templates/shoulda/helper.rb +1 -1
- data/lib/jeweler/templates/testunit/helper.rb +1 -1
- data/lib/jeweler/version_helper.rb +78 -33
- data/lib/jeweler.rb +5 -0
- data/test/fixtures/existing-project-with-version-plaintext/.document +5 -0
- data/test/fixtures/existing-project-with-version-plaintext/.gitignore +5 -0
- data/test/fixtures/{existing-project-with-version → existing-project-with-version-plaintext}/LICENSE +0 -0
- data/test/fixtures/{existing-project-with-version → existing-project-with-version-plaintext}/README.rdoc +0 -0
- data/test/fixtures/{existing-project-with-version → existing-project-with-version-plaintext}/Rakefile +0 -0
- data/test/fixtures/existing-project-with-version-plaintext/VERSION +1 -0
- data/test/fixtures/{existing-project-with-version → existing-project-with-version-plaintext}/existing-project-with-version.gemspec +0 -0
- data/test/fixtures/{existing-project-with-version → existing-project-with-version-plaintext}/lib/existing_project_with_version.rb +0 -0
- data/test/fixtures/{existing-project-with-version → existing-project-with-version-plaintext}/test/existing_project_with_version_test.rb +0 -0
- data/test/fixtures/{existing-project-with-version → existing-project-with-version-plaintext}/test/test_helper.rb +0 -0
- data/test/fixtures/existing-project-with-version-yaml/.document +5 -0
- data/test/fixtures/existing-project-with-version-yaml/.gitignore +5 -0
- data/test/fixtures/existing-project-with-version-yaml/LICENSE +20 -0
- data/test/fixtures/existing-project-with-version-yaml/README.rdoc +7 -0
- data/test/fixtures/existing-project-with-version-yaml/Rakefile +82 -0
- data/test/fixtures/{existing-project-with-version → existing-project-with-version-yaml}/VERSION.yml +0 -0
- data/test/fixtures/existing-project-with-version-yaml/existing-project-with-version.gemspec +29 -0
- data/test/fixtures/existing-project-with-version-yaml/lib/existing_project_with_version.rb +0 -0
- data/test/fixtures/existing-project-with-version-yaml/test/existing_project_with_version_test.rb +7 -0
- data/test/fixtures/existing-project-with-version-yaml/test/test_helper.rb +10 -0
- data/test/jeweler/commands/test_release.rb +304 -79
- data/test/test_application.rb +26 -0
- data/test/test_gemspec_helper.rb +4 -0
- data/test/test_generator.rb +83 -112
- data/test/test_generator_initialization.rb +113 -0
- data/test/test_generator_mixins.rb +18 -0
- data/test/test_helper.rb +3 -0
- data/test/test_options.rb +6 -0
- data/test/test_specification.rb +6 -2
- data/test/test_version_helper.rb +47 -9
- metadata +72 -17
- data/test/generators/initialization_test.rb +0 -146
data/.gitignore
ADDED
data/ChangeLog.markdown
CHANGED
@@ -1,3 +1,11 @@
|
|
1
|
+
# jeweler 0.11.1
|
2
|
+
|
3
|
+
* Lots of internal refactorings to how project generation happens
|
4
|
+
* Fixed missing dependency on rubyforge
|
5
|
+
* Depend on a recent version of schacon-git which works on ruby 1.9
|
6
|
+
* Updated cucumber support for 0.3.x
|
7
|
+
* Tested on Ruby 1.9
|
8
|
+
|
1
9
|
# jeweler 0.11.0 2009-04-05
|
2
10
|
|
3
11
|
* generator will respect JEWELER_OPTS, as a way to provide default options
|
data/README.markdown
CHANGED
@@ -5,12 +5,16 @@ Jeweler provides two things:
|
|
5
5
|
* Rake tasks for managing gems and versioning of a <a href="http://github.com">GitHub</a> project
|
6
6
|
* A generator for creating kickstarting a new project
|
7
7
|
|
8
|
+
## Quick Links
|
9
|
+
|
10
|
+
* [Wiki](http://wiki.github.com/technicalpickles/jeweler)
|
11
|
+
* [Bugs](http://github.com/technicalpickles/jeweler/issues)
|
12
|
+
* [Donate](http://pledgie.org/campaigns/2604)
|
13
|
+
|
8
14
|
## Installing
|
9
15
|
|
10
|
-
# Run the following if you haven't done so before:
|
11
|
-
gem sources -a http://gems.github.com
|
12
16
|
# Install the gem:
|
13
|
-
sudo gem install
|
17
|
+
sudo gem install jeweler
|
14
18
|
|
15
19
|
## Using in an existing project
|
16
20
|
|
@@ -30,7 +34,7 @@ It's easy to get up and running. Update your Rakefile to instantiate a `Jeweler:
|
|
30
34
|
puts "Jeweler not available. Install it with: sudo gem install technicalpickles-jeweler -s http://gems.github.com"
|
31
35
|
end
|
32
36
|
|
33
|
-
The yield object here, `gemspec`, is a `Gem::Specification` object. See the [
|
37
|
+
The yield object here, `gemspec`, is a `Gem::Specification` object. See the [Customizing your project's gem specification](http://wiki.github.com/technicalpickles/jeweler/customizing-your-projects-gem-specification) for more details about how you can customize your gemspec.
|
34
38
|
|
35
39
|
## Using to start a new project
|
36
40
|
|
@@ -119,7 +123,7 @@ With this in place, you now update your Jeweler::Tasks to setup `rubyforge_proje
|
|
119
123
|
s.rubyforge_project = 'the-perfect-gem' # This line would be new
|
120
124
|
end
|
121
125
|
rescue LoadError
|
122
|
-
puts "Jeweler not available. Install it with: sudo gem install
|
126
|
+
puts "Jeweler not available. Install it with: sudo gem install jeweler"
|
123
127
|
end
|
124
128
|
|
125
129
|
# These are new tasks
|
@@ -164,7 +168,3 @@ With all that setup out of the way, you can now release to RubyForge with impuni
|
|
164
168
|
* Have a delicious scotch
|
165
169
|
* Install [gemstalker](http://github.com/technicalpickles/gemstalker), and use it to know when gem is built. It typically builds in a few minutes, but won't be installable for another 15 minutes.
|
166
170
|
|
167
|
-
## Links
|
168
|
-
|
169
|
-
* [Bugs](http://technicalpickles.lighthouseapp.com/projects/23560-jeweler/overview)
|
170
|
-
* [Donate](http://pledgie.org/campaigns/2604)
|
data/ROADMAP
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
= 1.0
|
2
|
+
|
3
|
+
* Improve documentation on wiki/readme
|
4
|
+
|
5
|
+
= Unscheduled, or waiting for contributions
|
6
|
+
|
7
|
+
* Add command to output the Jeweler::Tasks to help with upgrading/migrating
|
8
|
+
* Support github user/token on generator command line
|
9
|
+
* Support C extensions
|
10
|
+
* Support JRuby gems
|
11
|
+
* Support thor
|
12
|
+
* Dealing with version bumps in other remotes
|
data/Rakefile
CHANGED
@@ -2,6 +2,9 @@ require 'rake'
|
|
2
2
|
|
3
3
|
$LOAD_PATH.unshift('lib')
|
4
4
|
|
5
|
+
gem 'git'
|
6
|
+
require 'git'
|
7
|
+
|
5
8
|
begin
|
6
9
|
require 'jeweler'
|
7
10
|
Jeweler::Tasks.new do |gem|
|
@@ -12,19 +15,21 @@ begin
|
|
12
15
|
gem.description = "Simple and opinionated helper for creating Rubygem projects on GitHub"
|
13
16
|
gem.authors = ["Josh Nichols"]
|
14
17
|
gem.files.include %w(lib/jeweler/templates/.document lib/jeweler/templates/.gitignore)
|
15
|
-
gem.add_dependency "
|
18
|
+
gem.add_dependency "git", ">= 1.1.1"
|
19
|
+
gem.add_dependency "rubyforge"
|
16
20
|
gem.rubyforge_project = "pickles"
|
17
21
|
end
|
18
22
|
rescue LoadError
|
19
|
-
puts "Jeweler, or one of its dependencies, is not available. Install it with: sudo gem install
|
23
|
+
puts "Jeweler, or one of its dependencies, is not available. Install it with: sudo gem install jeweler"
|
20
24
|
end
|
21
25
|
|
22
26
|
require 'rake/testtask'
|
23
27
|
Rake::TestTask.new(:test) do |test|
|
24
|
-
test.
|
28
|
+
test.test_files = FileList.new('test/**/test_*.rb') do |list|
|
29
|
+
list.exclude 'test/test_helper.rb'
|
30
|
+
end
|
25
31
|
test.libs << 'test'
|
26
32
|
test.verbose = true
|
27
|
-
#test.ruby_opts << '-rtest_helper'
|
28
33
|
end
|
29
34
|
|
30
35
|
require 'rake/rdoctask'
|
@@ -49,11 +54,23 @@ end
|
|
49
54
|
|
50
55
|
begin
|
51
56
|
require 'cucumber/rake/task'
|
52
|
-
Cucumber::Rake::Task.new(:features)
|
57
|
+
Cucumber::Rake::Task.new(:features) do |features|
|
58
|
+
features.cucumber_opts = "features --format progress"
|
59
|
+
end
|
60
|
+
namespace :features do
|
61
|
+
Cucumber::Rake::Task.new(:pretty) do |features|
|
62
|
+
features.cucumber_opts = "features --format progress"
|
63
|
+
end
|
64
|
+
end
|
53
65
|
rescue LoadError
|
54
66
|
task :features do
|
55
67
|
abort "Cucumber is not available. In order to run features, you must: sudo gem install cucumber"
|
56
68
|
end
|
69
|
+
namespace :features do
|
70
|
+
task :pretty do
|
71
|
+
abort "Cucumber is not available. In order to run features, you must: sudo gem install cucumber"
|
72
|
+
end
|
73
|
+
end
|
57
74
|
end
|
58
75
|
|
59
76
|
begin
|
data/VERSION.yml
CHANGED
@@ -0,0 +1,83 @@
|
|
1
|
+
Feature: generating cucumber stories
|
2
|
+
In order to get started using cucumber in a project
|
3
|
+
A user should be able to
|
4
|
+
generate a project setup for their testing framework of choice
|
5
|
+
|
6
|
+
Scenario: sans cucumber setup
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
And I do not want cucumber stories
|
10
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
11
|
+
|
12
|
+
And a file named 'the-perfect-gem/features/the-perfect-gem.feature' is not created
|
13
|
+
And a file named 'the-perfect-gem/features/support/env.rb' is not created
|
14
|
+
And a file named 'the-perfect-gem/features/steps/the-perfect-gem_steps.rb' is not created
|
15
|
+
|
16
|
+
Scenario: basic cucumber setup
|
17
|
+
Given a working directory
|
18
|
+
And I have configured git sanely
|
19
|
+
And I want cucumber stories
|
20
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
21
|
+
|
22
|
+
Then cucumber directories are created
|
23
|
+
|
24
|
+
And a file named 'the-perfect-gem/features/the-perfect-gem.feature' is created
|
25
|
+
And a file named 'the-perfect-gem/features/support/env.rb' is created
|
26
|
+
And a file named 'the-perfect-gem/features/step_definitions/the-perfect-gem_steps.rb' is created
|
27
|
+
|
28
|
+
And 'features/support/env.rb' requires 'the-perfect-gem'
|
29
|
+
|
30
|
+
Scenario: cucumber setup for bacon
|
31
|
+
Given a working directory
|
32
|
+
And I have configured git sanely
|
33
|
+
And I want cucumber stories
|
34
|
+
When I generate a bacon project named 'the-perfect-gem' that is 'zomg, so good'
|
35
|
+
|
36
|
+
Then 'features/support/env.rb' requires 'test/unit/assertions'
|
37
|
+
And cucumber world extends "Test::Unit::Assertions"
|
38
|
+
|
39
|
+
Scenario: cucumber setup for shoulda
|
40
|
+
Given a working directory
|
41
|
+
And I have configured git sanely
|
42
|
+
And I want cucumber stories
|
43
|
+
When I generate a shoulda project named 'the-perfect-gem' that is 'zomg, so good'
|
44
|
+
|
45
|
+
Then 'features/support/env.rb' requires 'test/unit/assertions'
|
46
|
+
And cucumber world extends "Test::Unit::Assertions"
|
47
|
+
|
48
|
+
Scenario: cucumber setup for testunit
|
49
|
+
Given a working directory
|
50
|
+
And I have configured git sanely
|
51
|
+
And I want cucumber stories
|
52
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
53
|
+
|
54
|
+
Then 'features/support/env.rb' requires 'test/unit/assertions'
|
55
|
+
And cucumber world extends "Test::Unit::Assertions"
|
56
|
+
|
57
|
+
Scenario: cucumber setup for minitest
|
58
|
+
Given a working directory
|
59
|
+
And I have configured git sanely
|
60
|
+
And I want cucumber stories
|
61
|
+
When I generate a minitest project named 'the-perfect-gem' that is 'zomg, so good'
|
62
|
+
|
63
|
+
Then 'features/support/env.rb' requires 'mini/test'
|
64
|
+
And cucumber world extends "Mini::Test::Assertions"
|
65
|
+
|
66
|
+
Scenario: cucumber setup for rspec
|
67
|
+
Given a working directory
|
68
|
+
And I have configured git sanely
|
69
|
+
And I want cucumber stories
|
70
|
+
When I generate a rspec project named 'the-perfect-gem' that is 'zomg, so good'
|
71
|
+
|
72
|
+
Then 'features/support/env.rb' requires 'the-perfect-gem'
|
73
|
+
And 'features/support/env.rb' requires 'spec/expectations'
|
74
|
+
|
75
|
+
Scenario: cucumber setup for mirconaut
|
76
|
+
Given a working directory
|
77
|
+
And I have configured git sanely
|
78
|
+
And I want cucumber stories
|
79
|
+
When I generate a micronaut project named 'the-perfect-gem' that is 'zomg, so good'
|
80
|
+
|
81
|
+
Then 'features/support/env.rb' requires 'the-perfect-gem'
|
82
|
+
And 'features/support/env.rb' requires 'micronaut/expectations'
|
83
|
+
And cucumber world extends "Micronaut::Matchers"
|
@@ -0,0 +1,76 @@
|
|
1
|
+
Feature: generated directory layout
|
2
|
+
In order to start a new gem
|
3
|
+
A user should be able to
|
4
|
+
generate a directory layout
|
5
|
+
|
6
|
+
Scenario: shared
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
10
|
+
|
11
|
+
Then a directory named 'the-perfect-gem' is created
|
12
|
+
And a directory named 'the-perfect-gem/lib' is created
|
13
|
+
|
14
|
+
And a file named 'the-perfect-gem/README.rdoc' is created
|
15
|
+
And a file named 'the-perfect-gem/.document' is created
|
16
|
+
And a file named 'the-perfect-gem/lib/the-perfect-gem.rb' is created
|
17
|
+
|
18
|
+
Scenario: bacon
|
19
|
+
Given a working directory
|
20
|
+
And I have configured git sanely
|
21
|
+
When I generate a bacon project named 'the-perfect-gem' that is 'zomg, so good'
|
22
|
+
|
23
|
+
Then a directory named 'the-perfect-gem/spec' is created
|
24
|
+
|
25
|
+
And a file named 'the-perfect-gem/spec/spec_helper.rb' is created
|
26
|
+
And a file named 'the-perfect-gem/spec/the-perfect-gem_spec.rb' is created
|
27
|
+
|
28
|
+
Scenario: minitest
|
29
|
+
Given a working directory
|
30
|
+
And I have configured git sanely
|
31
|
+
When I generate a minitest project named 'the-perfect-gem' that is 'zomg, so good'
|
32
|
+
|
33
|
+
Then a directory named 'the-perfect-gem/test' is created
|
34
|
+
|
35
|
+
And a file named 'the-perfect-gem/test/test_helper.rb' is created
|
36
|
+
And a file named 'the-perfect-gem/test/the-perfect-gem_test.rb' is created
|
37
|
+
|
38
|
+
Scenario: rspec
|
39
|
+
Given a working directory
|
40
|
+
And I have configured git sanely
|
41
|
+
When I generate a rspec project named 'the-perfect-gem' that is 'zomg, so good'
|
42
|
+
|
43
|
+
Then a directory named 'the-perfect-gem/spec' is created
|
44
|
+
|
45
|
+
And a file named 'the-perfect-gem/spec/spec_helper.rb' is created
|
46
|
+
And a file named 'the-perfect-gem/spec/the-perfect-gem_spec.rb' is created
|
47
|
+
|
48
|
+
Scenario: shoulda
|
49
|
+
Given a working directory
|
50
|
+
And I have configured git sanely
|
51
|
+
When I generate a shoulda project named 'the-perfect-gem' that is 'zomg, so good'
|
52
|
+
|
53
|
+
Then a directory named 'the-perfect-gem/test' is created
|
54
|
+
|
55
|
+
And a file named 'the-perfect-gem/test/test_helper.rb' is created
|
56
|
+
And a file named 'the-perfect-gem/test/the-perfect-gem_test.rb' is created
|
57
|
+
|
58
|
+
Scenario: testunit
|
59
|
+
Given a working directory
|
60
|
+
And I have configured git sanely
|
61
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
62
|
+
|
63
|
+
Then a directory named 'the-perfect-gem/test' is created
|
64
|
+
|
65
|
+
And a file named 'the-perfect-gem/test/test_helper.rb' is created
|
66
|
+
And a file named 'the-perfect-gem/test/the-perfect-gem_test.rb' is created
|
67
|
+
|
68
|
+
Scenario: micronaut
|
69
|
+
Given a working directory
|
70
|
+
And I have configured git sanely
|
71
|
+
When I generate a micronaut project named 'the-perfect-gem' that is 'zomg, so good'
|
72
|
+
|
73
|
+
Then a directory named 'the-perfect-gem/examples' is created
|
74
|
+
|
75
|
+
And a file named 'the-perfect-gem/examples/example_helper.rb' is created
|
76
|
+
And a file named 'the-perfect-gem/examples/the-perfect-gem_example.rb' is created
|
@@ -0,0 +1,14 @@
|
|
1
|
+
Feature: generated .document
|
2
|
+
In order to easily generate RDoc
|
3
|
+
A user should be able to
|
4
|
+
generate reasonable .document file
|
5
|
+
|
6
|
+
Scenario: .document
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
10
|
+
Then '.document' contains 'README.rdoc'
|
11
|
+
And '.document' contains 'lib/**/*.rb'
|
12
|
+
And '.document' contains 'bin/*'
|
13
|
+
And '.document' contains 'features/**/*.feature'
|
14
|
+
And '.document' contains 'LICENSE'
|
@@ -0,0 +1,9 @@
|
|
1
|
+
Feature: Getting options from environment variable
|
2
|
+
In order to avoid having to type --rspec over and over
|
3
|
+
A user will need to set up a JEWELER_OPTS environment variable
|
4
|
+
|
5
|
+
Scenario: Environment variable set
|
6
|
+
Given a working directory
|
7
|
+
And I set JEWELER_OPTS env variable to "--rspec"
|
8
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
9
|
+
Then 'spec/the-perfect-gem_spec.rb' should describe 'ThePerfectGem'
|
@@ -0,0 +1,94 @@
|
|
1
|
+
Feature: git support
|
2
|
+
In order to start a new gem for GitHub
|
3
|
+
A user should be able to
|
4
|
+
generate a project that is setup for git
|
5
|
+
|
6
|
+
Scenario: git remote configuration
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
10
|
+
|
11
|
+
Then git repository has 'origin' remote
|
12
|
+
And git repository 'origin' remote should be 'git@github.com:technicalpickles/the-perfect-gem.git'
|
13
|
+
|
14
|
+
Scenario: .gitignore
|
15
|
+
Given a working directory
|
16
|
+
And I have configured git sanely
|
17
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
18
|
+
|
19
|
+
Then a sane '.gitignore' is created
|
20
|
+
|
21
|
+
Scenario: baseline repository
|
22
|
+
Given a working directory
|
23
|
+
And I have configured git sanely
|
24
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
25
|
+
|
26
|
+
Then a commit with the message 'Initial commit to the-perfect-gem.' is made
|
27
|
+
And 'README.rdoc' was checked in
|
28
|
+
And 'Rakefile' was checked in
|
29
|
+
And 'LICENSE' was checked in
|
30
|
+
And 'lib/the-perfect-gem.rb' was checked in
|
31
|
+
And '.gitignore' was checked in
|
32
|
+
|
33
|
+
And no files are untracked
|
34
|
+
And no files are changed
|
35
|
+
And no files are added
|
36
|
+
And no files are deleted
|
37
|
+
|
38
|
+
Scenario: bacon
|
39
|
+
Given a working directory
|
40
|
+
And I have configured git sanely
|
41
|
+
When I generate a bacon project named 'the-perfect-gem' that is 'zomg, so good'
|
42
|
+
|
43
|
+
Then 'spec/spec_helper.rb' was checked in
|
44
|
+
And 'spec/the-perfect-gem_spec.rb' was checked in
|
45
|
+
|
46
|
+
Scenario: minitest
|
47
|
+
Given a working directory
|
48
|
+
And I have configured git sanely
|
49
|
+
When I generate a minitest project named 'the-perfect-gem' that is 'zomg, so good'
|
50
|
+
|
51
|
+
Then 'test/test_helper.rb' was checked in
|
52
|
+
And 'test/the-perfect-gem_test.rb' was checked in
|
53
|
+
|
54
|
+
Scenario: rspec
|
55
|
+
Given a working directory
|
56
|
+
And I have configured git sanely
|
57
|
+
When I generate a rspec project named 'the-perfect-gem' that is 'zomg, so good'
|
58
|
+
|
59
|
+
Then 'spec/spec_helper.rb' was checked in
|
60
|
+
And 'spec/the-perfect-gem_spec.rb' was checked in
|
61
|
+
|
62
|
+
Scenario: shoulda
|
63
|
+
Given a working directory
|
64
|
+
And I have configured git sanely
|
65
|
+
When I generate a shoulda project named 'the-perfect-gem' that is 'zomg, so good'
|
66
|
+
|
67
|
+
Then 'test/test_helper.rb' was checked in
|
68
|
+
And 'test/the-perfect-gem_test.rb' was checked in
|
69
|
+
|
70
|
+
Scenario: testunit
|
71
|
+
Given a working directory
|
72
|
+
And I have configured git sanely
|
73
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
74
|
+
|
75
|
+
Then 'test/test_helper.rb' was checked in
|
76
|
+
And 'test/the-perfect-gem_test.rb' was checked in
|
77
|
+
|
78
|
+
Scenario: micronaut
|
79
|
+
Given a working directory
|
80
|
+
And I have configured git sanely
|
81
|
+
When I generate a micronaut project named 'the-perfect-gem' that is 'zomg, so good'
|
82
|
+
|
83
|
+
Then 'examples/example_helper.rb' was checked in
|
84
|
+
And 'examples/the-perfect-gem_example.rb' was checked in
|
85
|
+
|
86
|
+
Scenario: cucumber
|
87
|
+
Given a working directory
|
88
|
+
And I have configured git sanely
|
89
|
+
And I want cucumber stories
|
90
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
91
|
+
|
92
|
+
Then 'features/the-perfect-gem.feature' was checked in
|
93
|
+
And 'features/support/env.rb' was checked in
|
94
|
+
And 'features/step_definitions/the-perfect-gem_steps.rb' was checked in
|
@@ -0,0 +1,11 @@
|
|
1
|
+
Feature: generated license
|
2
|
+
In order to start a new gem
|
3
|
+
A user should be able to
|
4
|
+
generate a default license
|
5
|
+
|
6
|
+
Scenario: copyright
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
10
|
+
|
11
|
+
Then LICENSE has the copyright as belonging to 'foo' in '2009'
|
@@ -0,0 +1,110 @@
|
|
1
|
+
Feature: generated Rakefile
|
2
|
+
In order to start a new gem
|
3
|
+
A user should be able to
|
4
|
+
generate a Rakefile
|
5
|
+
|
6
|
+
Scenario: shared
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
10
|
+
|
11
|
+
Then 'Rakefile' requires 'rubygems'
|
12
|
+
And 'Rakefile' requires 'rake'
|
13
|
+
And 'Rakefile' requires 'rake/rdoctask'
|
14
|
+
And Rakefile has 'the-perfect-gem' for the Jeweler::Tasks name
|
15
|
+
And Rakefile has 'bar@example.com' for the Jeweler::Tasks email
|
16
|
+
And Rakefile has 'zomg, so good' for the Jeweler::Tasks summary
|
17
|
+
And Rakefile has 'http://github.com/technicalpickles/the-perfect-gem' for the Jeweler::Tasks homepage
|
18
|
+
|
19
|
+
Scenario: bacon
|
20
|
+
Given a working directory
|
21
|
+
And I have configured git sanely
|
22
|
+
When I generate a bacon project named 'the-perfect-gem' that is 'zomg, so good'
|
23
|
+
|
24
|
+
|
25
|
+
Then 'Rakefile' requires 'rcov/rcovtask'
|
26
|
+
And Rakefile has 'spec/**/*_spec.rb' for the Rake::TestTask pattern
|
27
|
+
And Rakefile has 'spec/**/*_spec.rb' for the Rcov::RcovTask pattern
|
28
|
+
And Rakefile has 'spec' in the Rcov::RcovTask libs
|
29
|
+
And Rakefile has "spec" as the default task
|
30
|
+
|
31
|
+
Scenario: minitest
|
32
|
+
Given a working directory
|
33
|
+
And I have configured git sanely
|
34
|
+
When I generate a minitest project named 'the-perfect-gem' that is 'zomg, so good'
|
35
|
+
|
36
|
+
Then 'Rakefile' requires 'rcov/rcovtask'
|
37
|
+
And Rakefile has 'test/**/*_test.rb' for the Rake::TestTask pattern
|
38
|
+
And Rakefile has 'test/**/*_test.rb' for the Rcov::RcovTask pattern
|
39
|
+
And Rakefile has 'test' in the Rcov::RcovTask libs
|
40
|
+
And Rakefile has "test" as the default task
|
41
|
+
|
42
|
+
Scenario: rspec
|
43
|
+
Given a working directory
|
44
|
+
And I have configured git sanely
|
45
|
+
When I generate a rspec project named 'the-perfect-gem' that is 'zomg, so good'
|
46
|
+
|
47
|
+
Then 'Rakefile' requires 'spec/rake/spectask'
|
48
|
+
And Rakefile has 'spec/**/*_spec.rb' for the Spec::Rake::SpecTask pattern
|
49
|
+
And Rakefile has "spec" as the default task
|
50
|
+
|
51
|
+
Scenario: shoulda
|
52
|
+
Given a working directory
|
53
|
+
And I have configured git sanely
|
54
|
+
When I generate a shoulda project named 'the-perfect-gem' that is 'zomg, so good'
|
55
|
+
|
56
|
+
Then 'Rakefile' requires 'rcov/rcovtask'
|
57
|
+
And Rakefile has 'test/**/*_test.rb' for the Rake::TestTask pattern
|
58
|
+
And Rakefile has 'test/**/*_test.rb' for the Rcov::RcovTask pattern
|
59
|
+
And Rakefile has 'test' in the Rcov::RcovTask libs
|
60
|
+
And Rakefile has "test" as the default task
|
61
|
+
|
62
|
+
Scenario: micronaut
|
63
|
+
Given a working directory
|
64
|
+
And I have configured git sanely
|
65
|
+
When I generate a micronaut project named 'the-perfect-gem' that is 'zomg, so good'
|
66
|
+
|
67
|
+
Then 'Rakefile' requires 'micronaut/rake_task'
|
68
|
+
And Rakefile has 'examples/**/*_example.rb' for the Micronaut::RakeTask pattern
|
69
|
+
And Rakefile has "examples" as the default task
|
70
|
+
|
71
|
+
Scenario: testunit
|
72
|
+
Given a working directory
|
73
|
+
And I have configured git sanely
|
74
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
75
|
+
|
76
|
+
Then 'Rakefile' requires 'rcov/rcovtask'
|
77
|
+
Then Rakefile has 'test/**/*_test.rb' for the Rake::TestTask pattern
|
78
|
+
And Rakefile has 'test/**/*_test.rb' for the Rcov::RcovTask pattern
|
79
|
+
And Rakefile has 'test' in the Rcov::RcovTask libs
|
80
|
+
And Rakefile has "test" as the default task
|
81
|
+
|
82
|
+
Scenario: no cucumber
|
83
|
+
Given a working directory
|
84
|
+
And I have configured git sanely
|
85
|
+
And I do not want cucumber stories
|
86
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
87
|
+
Then Rakefile does not require 'cucumber/rake/task'
|
88
|
+
And Rakefile does not instantiate a Cucumber::Rake::Task
|
89
|
+
|
90
|
+
Scenario: cucumber
|
91
|
+
Given a working directory
|
92
|
+
And I have configured git sanely
|
93
|
+
And I want cucumber stories
|
94
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
95
|
+
Then Rakefile requires 'cucumber/rake/task'
|
96
|
+
And Rakefile instantiates a Cucumber::Rake::Task
|
97
|
+
|
98
|
+
Scenario: no rubyforge
|
99
|
+
Given a working directory
|
100
|
+
And I have configured git sanely
|
101
|
+
And I do not want rubyforge setup
|
102
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
103
|
+
Then Rakefile does not instantiate a Jeweler::RubyforgeTasks
|
104
|
+
|
105
|
+
Scenario: rubyforge
|
106
|
+
Given a working directory
|
107
|
+
And I have configured git sanely
|
108
|
+
And I want rubyforge setup
|
109
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
110
|
+
Then Rakefile instantiates a Jeweler::RubyforgeTasks
|
@@ -0,0 +1,12 @@
|
|
1
|
+
Feature: generated license
|
2
|
+
In order to start a new gem
|
3
|
+
A user should be able to
|
4
|
+
generate a default license
|
5
|
+
|
6
|
+
Scenario: copyright
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
10
|
+
|
11
|
+
Then 'README.rdoc' contains '= the-perfect-gem'
|
12
|
+
And 'README.rdoc' mentions copyright belonging to me in the current year
|
@@ -0,0 +1,41 @@
|
|
1
|
+
Feature: generated test or spec
|
2
|
+
In order to start a new gem
|
3
|
+
A user should be able to
|
4
|
+
generate a test or spec
|
5
|
+
|
6
|
+
Scenario: bacon
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
When I generate a bacon project named 'the-perfect-gem' that is 'zomg, so good'
|
10
|
+
Then 'spec/the-perfect-gem_spec.rb' should describe 'ThePerfectGem'
|
11
|
+
|
12
|
+
Scenario: minitest
|
13
|
+
Given a working directory
|
14
|
+
And I have configured git sanely
|
15
|
+
When I generate a minitest project named 'the-perfect-gem' that is 'zomg, so good'
|
16
|
+
Then 'test/the-perfect-gem_test.rb' should define 'ThePerfectGemTest' as a subclass of 'Mini::Test::TestCase'
|
17
|
+
|
18
|
+
Scenario: rspec
|
19
|
+
Given a working directory
|
20
|
+
And I have configured git sanely
|
21
|
+
When I generate a rspec project named 'the-perfect-gem' that is 'zomg, so good'
|
22
|
+
Then 'spec/the-perfect-gem_spec.rb' should describe 'ThePerfectGem'
|
23
|
+
|
24
|
+
Scenario: shoulda
|
25
|
+
Given a working directory
|
26
|
+
And I have configured git sanely
|
27
|
+
And I intend to test with shoulda
|
28
|
+
When I generate a project named 'the-perfect-gem' that is 'zomg, so good'
|
29
|
+
Then 'test/the-perfect-gem_test.rb' should define 'ThePerfectGemTest' as a subclass of 'Test::Unit::TestCase'
|
30
|
+
|
31
|
+
Scenario: testunit
|
32
|
+
Given a working directory
|
33
|
+
And I have configured git sanely
|
34
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
35
|
+
Then 'test/the-perfect-gem_test.rb' should define 'ThePerfectGemTest' as a subclass of 'Test::Unit::TestCase'
|
36
|
+
|
37
|
+
Scenario: micronaut
|
38
|
+
Given a working directory
|
39
|
+
And I have configured git sanely
|
40
|
+
When I generate a micronaut project named 'the-perfect-gem' that is 'zomg, so good'
|
41
|
+
Then 'examples/the-perfect-gem_example.rb' should describe 'ThePerfectGem'
|
@@ -0,0 +1,49 @@
|
|
1
|
+
Feature: generated test or spec
|
2
|
+
In order to start a new gem
|
3
|
+
A user should be able to
|
4
|
+
generate a test or spec
|
5
|
+
|
6
|
+
Scenario: bacon
|
7
|
+
Given a working directory
|
8
|
+
And I have configured git sanely
|
9
|
+
When I generate a bacon project named 'the-perfect-gem' that is 'zomg, so good'
|
10
|
+
Then 'spec/spec_helper.rb' requires 'bacon'
|
11
|
+
And 'spec/spec_helper.rb' requires 'the-perfect-gem'
|
12
|
+
|
13
|
+
Scenario: minitest
|
14
|
+
Given a working directory
|
15
|
+
And I have configured git sanely
|
16
|
+
When I generate a minitest project named 'the-perfect-gem' that is 'zomg, so good'
|
17
|
+
Then 'test/test_helper.rb' requires 'mini/test'
|
18
|
+
And 'test/test_helper.rb' requires 'the-perfect-gem'
|
19
|
+
And 'test/test_helper.rb' should autorun tests
|
20
|
+
|
21
|
+
Scenario: rspec
|
22
|
+
Given a working directory
|
23
|
+
And I have configured git sanely
|
24
|
+
When I generate a rspec project named 'the-perfect-gem' that is 'zomg, so good'
|
25
|
+
Then 'spec/spec_helper.rb' requires 'spec'
|
26
|
+
And 'spec/spec_helper.rb' requires 'the-perfect-gem'
|
27
|
+
|
28
|
+
Scenario: shoulda
|
29
|
+
Given a working directory
|
30
|
+
And I have configured git sanely
|
31
|
+
When I generate a shoulda project named 'the-perfect-gem' that is 'zomg, so good'
|
32
|
+
Then 'test/test_helper.rb' requires 'test/unit'
|
33
|
+
And 'test/test_helper.rb' requires 'shoulda'
|
34
|
+
And 'test/test_helper.rb' requires 'the-perfect-gem'
|
35
|
+
|
36
|
+
Scenario: testunit
|
37
|
+
Given a working directory
|
38
|
+
And I have configured git sanely
|
39
|
+
When I generate a testunit project named 'the-perfect-gem' that is 'zomg, so good'
|
40
|
+
Then 'test/test_helper.rb' requires 'test/unit'
|
41
|
+
And 'test/test_helper.rb' requires 'the-perfect-gem'
|
42
|
+
|
43
|
+
Scenario: micronaut
|
44
|
+
Given a working directory
|
45
|
+
And I have configured git sanely
|
46
|
+
When I generate a micronaut project named 'the-perfect-gem' that is 'zomg, so good'
|
47
|
+
Then 'examples/example_helper.rb' requires 'rubygems'
|
48
|
+
Then 'examples/example_helper.rb' requires 'micronaut'
|
49
|
+
Then 'examples/example_helper.rb' requires 'the-perfect-gem'
|