git-pr-release 0.6.0 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/.rspec +1 -0
- data/bin/git-pr-release +132 -113
- data/git-pr-release.gemspec +4 -1
- data/spec/bin_spec.rb +136 -0
- data/spec/fixtures/file/pr_1.yml +330 -0
- data/spec/fixtures/file/pr_1_files.yml +14 -0
- data/spec/fixtures/file/pr_3.yml +332 -0
- data/spec/fixtures/file/pr_4.yml +334 -0
- data/spec/fixtures/file/pr_6.yml +339 -0
- data/spec/fixtures/file/template_1.erb +2 -0
- data/spec/fixtures/file/template_2.erb +2 -0
- data/spec/spec_helper.rb +25 -0
- data/spec/support/capture_support.rb +17 -0
- data/spec/support/file_fixture_support.rb +19 -0
- metadata +55 -5
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
require "timecop"
|
2
|
+
require "yaml"
|
3
|
+
|
4
|
+
RSpec.configure do |config|
|
5
|
+
config.expect_with :rspec do |expectations|
|
6
|
+
expectations.include_chain_clauses_in_custom_matcher_descriptions = true
|
7
|
+
end
|
8
|
+
config.mock_with :rspec do |mocks|
|
9
|
+
mocks.verify_partial_doubles = true
|
10
|
+
end
|
11
|
+
config.shared_context_metadata_behavior = :apply_to_host_groups
|
12
|
+
|
13
|
+
config.filter_run_when_matching :focus
|
14
|
+
config.example_status_persistence_file_path = ".rspec_status"
|
15
|
+
config.disable_monkey_patching!
|
16
|
+
config.warnings = true
|
17
|
+
config.order = :random
|
18
|
+
Kernel.srand config.seed
|
19
|
+
|
20
|
+
config.after do
|
21
|
+
Timecop.return
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
Dir[File.expand_path("support/**/*.rb", __dir__)].each {|f| require f }
|
@@ -0,0 +1,17 @@
|
|
1
|
+
module CaptureSupport
|
2
|
+
def capture(stream)
|
3
|
+
begin
|
4
|
+
eval "$#{stream} = StringIO.new"
|
5
|
+
yield
|
6
|
+
result = eval("$#{stream}").string
|
7
|
+
ensure
|
8
|
+
eval("$#{stream} = #{stream.upcase}")
|
9
|
+
end
|
10
|
+
|
11
|
+
result
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
RSpec.configure do |config|
|
16
|
+
config.include CaptureSupport
|
17
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module FileFixtureSupport
|
2
|
+
def file_fixture(fixture_name)
|
3
|
+
file_fixture_path = RSpec.configuration.file_fixture_path
|
4
|
+
path = Pathname.new(File.join(file_fixture_path, fixture_name))
|
5
|
+
|
6
|
+
if path.exist?
|
7
|
+
path
|
8
|
+
else
|
9
|
+
msg = "the directory '%s' does not contain a file named '%s'"
|
10
|
+
raise ArgumentError, msg % [file_fixture_path, fixture_name]
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
RSpec.configure do |config|
|
16
|
+
config.add_setting :file_fixture_path
|
17
|
+
config.file_fixture_path = File.expand_path("../fixtures/file", __dir__)
|
18
|
+
config.include FileFixtureSupport
|
19
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: git-pr-release
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- motemen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-03-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: octokit
|
@@ -66,6 +66,34 @@ dependencies:
|
|
66
66
|
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rspec
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: timecop
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
69
97
|
description: git-pr-release creates a pull request which summarizes feature branches
|
70
98
|
that are to be released into production
|
71
99
|
email:
|
@@ -76,12 +104,24 @@ extensions: []
|
|
76
104
|
extra_rdoc_files: []
|
77
105
|
files:
|
78
106
|
- ".gitignore"
|
107
|
+
- ".rspec"
|
79
108
|
- Gemfile
|
80
109
|
- LICENSE
|
81
110
|
- README.md
|
82
111
|
- Rakefile
|
83
112
|
- bin/git-pr-release
|
84
113
|
- git-pr-release.gemspec
|
114
|
+
- spec/bin_spec.rb
|
115
|
+
- spec/fixtures/file/pr_1.yml
|
116
|
+
- spec/fixtures/file/pr_1_files.yml
|
117
|
+
- spec/fixtures/file/pr_3.yml
|
118
|
+
- spec/fixtures/file/pr_4.yml
|
119
|
+
- spec/fixtures/file/pr_6.yml
|
120
|
+
- spec/fixtures/file/template_1.erb
|
121
|
+
- spec/fixtures/file/template_2.erb
|
122
|
+
- spec/spec_helper.rb
|
123
|
+
- spec/support/capture_support.rb
|
124
|
+
- spec/support/file_fixture_support.rb
|
85
125
|
homepage: https://github.com/motemen/git-pr-release
|
86
126
|
licenses:
|
87
127
|
- MIT
|
@@ -101,9 +141,19 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
101
141
|
- !ruby/object:Gem::Version
|
102
142
|
version: '0'
|
103
143
|
requirements: []
|
104
|
-
|
105
|
-
rubygems_version: 2.7.8
|
144
|
+
rubygems_version: 3.0.3
|
106
145
|
signing_key:
|
107
146
|
specification_version: 4
|
108
147
|
summary: Creates a release pull request
|
109
|
-
test_files:
|
148
|
+
test_files:
|
149
|
+
- spec/bin_spec.rb
|
150
|
+
- spec/fixtures/file/pr_1.yml
|
151
|
+
- spec/fixtures/file/pr_1_files.yml
|
152
|
+
- spec/fixtures/file/pr_3.yml
|
153
|
+
- spec/fixtures/file/pr_4.yml
|
154
|
+
- spec/fixtures/file/pr_6.yml
|
155
|
+
- spec/fixtures/file/template_1.erb
|
156
|
+
- spec/fixtures/file/template_2.erb
|
157
|
+
- spec/spec_helper.rb
|
158
|
+
- spec/support/capture_support.rb
|
159
|
+
- spec/support/file_fixture_support.rb
|