rake_shared_context 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f39f02ee4b13e9ad053f4c49ef47a3b503c19e6d
4
- data.tar.gz: 5ca49db0be9fd08c8c895f5b5ab6fe6e67ece793
3
+ metadata.gz: 43056aed3d54e210601b1e817d8da7d42bd10b6d
4
+ data.tar.gz: f61117bd2f0ff5dff7d51ea514ec09fb9e1035c4
5
5
  SHA512:
6
- metadata.gz: 4ccd81b820e3e8893cda087a1570ceb3e50998f7bbcb29723fae565d6c1810a34eaf8459a1abb36e02ce898d1e9b8450fb2e2bac1e0f60e9224eb73963659d94
7
- data.tar.gz: 1d5484035f3c7658ad54f3b448ecf939a71f6391dc8175b871940e73a839010cda64c4440d417ffd2415cc4d33183a0d7116865a7add76575cc4cb3e63be0533
6
+ metadata.gz: 20e3b14c4ee25e86f530a7f9ccfa011c4be17ec41c59567fe6067e8989a039d3d88608e29220b80bb377051f90013ecb9ff6d3a14a82321ca007e8b7ebdb0051
7
+ data.tar.gz: 7c5e53331459c6ea44ae94920dfa547a3ceb1e4f1e5ad7f8175a2d011a4c477ffb1afac4e35cebb6bfd29adcc2014421bd97bf5971b8c16098319169946a8652
data/.gitignore CHANGED
@@ -16,4 +16,5 @@ test/tmp
16
16
  test/version_tmp
17
17
  tmp
18
18
  vendor/bundle
19
- bin
19
+ bin
20
+ *.gemfile.lock
data/.travis.yml CHANGED
@@ -1,5 +1,8 @@
1
1
  language: ruby
2
2
  rvm:
3
- - "1.9.3"
4
- - "2.0.0"
5
-
3
+ - '1.9.3'
4
+ - '2.0.0'
5
+ - '2.1.2'
6
+ gemfile:
7
+ - gemfiles/rspec_2.gemfile
8
+ - gemfiles/rspec_3.gemfile
data/Appraisals ADDED
@@ -0,0 +1,7 @@
1
+ appraise "rspec-2" do
2
+ gem "rspec", "2.14.1"
3
+ end
4
+
5
+ appraise "rspec-3" do
6
+ gem "rspec", "3.0.0"
7
+ end
data/Gemfile CHANGED
@@ -2,3 +2,5 @@ source 'https://rubygems.org'
2
2
 
3
3
  # Specify your gem's dependencies in rake_shared_context.gemspec
4
4
  gemspec
5
+
6
+ gem 'coveralls', require: false
data/README.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  [![Build Status](https://travis-ci.org/willnet/rake_shared_context.png)](https://travis-ci.org/willnet/rake_shared_context)
4
4
  [![Gem Version](https://badge.fury.io/rb/rake_shared_context.png)](http://badge.fury.io/rb/rake_shared_context)
5
+ [![Coverage Status](https://coveralls.io/repos/willnet/rake_shared_context/badge.png)](https://coveralls.io/r/willnet/rake_shared_context)
6
+ [![Stories in Ready](https://badge.waffle.io/willnet/rake_shared_context.png?label=ready&title=Ready)](https://waffle.io/willnet/rake_shared_context)
5
7
 
6
8
  shared_context for rake tasks.
7
9
 
@@ -29,7 +31,7 @@ If you have `rake reports:users` like following.
29
31
  # lib/tasks/reports.rake
30
32
  namespace :reports do
31
33
  desc "Generate report"
32
-
34
+
33
35
  task :generate => :environment do
34
36
  ReportGenerator.generate
35
37
  end
@@ -45,10 +47,12 @@ require 'spec_helper'
45
47
  describe "reports:generate" do
46
48
  include_context "rake"
47
49
 
48
- its(:prerequisites) { should include("environment") }
50
+ it 'prerequisites should include "environment"' do
51
+ expect(subject.prerequisites).to include('environment')
52
+ end
49
53
 
50
54
  it "generates the report" do
51
- ReportGenerator.should_receive(:generate)
55
+ expect(ReportGenerator).to receive(:generate)
52
56
  subject.invoke
53
57
  end
54
58
  end
@@ -59,6 +63,22 @@ end
59
63
  * It expects that rake files are located under lib/tasks
60
64
  * It expects that a argument is passed to `describe` is task name
61
65
 
66
+ ## Supported versions
67
+
68
+ * Ruby 1.9.3, 2.0.0, 2.1.2
69
+ * Rspec 2, 3
70
+
71
+ ## Development
72
+
73
+ To set up a development environment, do following
74
+
75
+ ```sh
76
+ bundle install
77
+ appraisal install
78
+ bundle exec appraisal rspec-2 rake # test with rspec 2
79
+ bundle exec appraisal rspec-3 rake # test with rspec 3
80
+ ```
81
+
62
82
  ## Contributing
63
83
 
64
84
  1. Fork it
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "coveralls", :require => false
6
+ gem "rspec", "2.14.1"
7
+
8
+ gemspec :path => "../"
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "coveralls", :require => false
6
+ gem "rspec", "3.0.0"
7
+
8
+ gemspec :path => "../"
@@ -35,7 +35,7 @@ end
35
35
 
36
36
  begin
37
37
  require "rspec/core"
38
- shared_context "rake" do
38
+ RSpec.shared_context "rake" do
39
39
  let(:rake) { Rake::Application.new }
40
40
  let(:task_name) { self.class.top_level_description }
41
41
  subject { rake[task_name] }
@@ -1,3 +1,3 @@
1
1
  class RakeSharedContext
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.1"
3
3
  end
@@ -7,7 +7,7 @@ Gem::Specification.new do |gem|
7
7
  gem.description = %q{shared_context for rake task}
8
8
  gem.summary = %q{shared_context for rake task}
9
9
  gem.homepage = "https://github.com/willnet/rake_shared_context"
10
-
10
+ gem.license = "MIT"
11
11
  gem.files = `git ls-files`.split($\)
12
12
  gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
13
13
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
@@ -15,6 +15,6 @@ Gem::Specification.new do |gem|
15
15
  gem.require_paths = ["lib"]
16
16
  gem.version = RakeSharedContext::VERSION
17
17
  gem.add_development_dependency "rake"
18
- gem.add_development_dependency "rspec"
18
+ gem.add_development_dependency "appraisal"
19
19
  gem.add_development_dependency "pry"
20
20
  end
data/spec/rake_spec.rb CHANGED
@@ -8,11 +8,13 @@ describe "reports:generate" do
8
8
 
9
9
  include_context "rake"
10
10
 
11
- its(:prerequisites) { should include("environment") }
11
+ it 'prerequisites should include "environment"' do
12
+ expect(subject.prerequisites).to include('environment')
13
+ end
14
+
12
15
 
13
16
  it "generates the report" do
14
- ReportGenerator.should_receive(:generate)
17
+ expect(ReportGenerator).to receive(:generate)
15
18
  subject.invoke
16
19
  end
17
20
  end
18
-
data/spec/spec_helper.rb CHANGED
@@ -1,2 +1,4 @@
1
+ require 'coveralls'
2
+ Coveralls.wear!
1
3
  require 'rspec'
2
4
  require 'rake_shared_context'
metadata CHANGED
@@ -1,55 +1,55 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rake_shared_context
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - willnet
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-11-06 00:00:00.000000000 Z
11
+ date: 2014-06-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '0'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
- name: rspec
28
+ name: appraisal
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: pry
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '0'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '>='
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
55
  description: shared_context for rake task
@@ -59,13 +59,16 @@ executables: []
59
59
  extensions: []
60
60
  extra_rdoc_files: []
61
61
  files:
62
- - .gitignore
63
- - .travis.yml
62
+ - ".gitignore"
63
+ - ".travis.yml"
64
+ - Appraisals
64
65
  - CHANGELOG.md
65
66
  - Gemfile
66
67
  - LICENSE
67
68
  - README.md
68
69
  - Rakefile
70
+ - gemfiles/rspec_2.gemfile
71
+ - gemfiles/rspec_3.gemfile
69
72
  - lib/rake_shared_context.rb
70
73
  - lib/rake_shared_context/version.rb
71
74
  - rake_shared_context.gemspec
@@ -75,7 +78,8 @@ files:
75
78
  - spec/rake_spec.rb
76
79
  - spec/spec_helper.rb
77
80
  homepage: https://github.com/willnet/rake_shared_context
78
- licenses: []
81
+ licenses:
82
+ - MIT
79
83
  metadata: {}
80
84
  post_install_message:
81
85
  rdoc_options: []
@@ -83,17 +87,17 @@ require_paths:
83
87
  - lib
84
88
  required_ruby_version: !ruby/object:Gem::Requirement
85
89
  requirements:
86
- - - '>='
90
+ - - ">="
87
91
  - !ruby/object:Gem::Version
88
92
  version: '0'
89
93
  required_rubygems_version: !ruby/object:Gem::Requirement
90
94
  requirements:
91
- - - '>='
95
+ - - ">="
92
96
  - !ruby/object:Gem::Version
93
97
  version: '0'
94
98
  requirements: []
95
99
  rubyforge_project:
96
- rubygems_version: 2.0.3
100
+ rubygems_version: 2.2.2
97
101
  signing_key:
98
102
  specification_version: 4
99
103
  summary: shared_context for rake task