bmp 1.2.0 → 1.3.1

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.
@@ -1,7 +1,35 @@
1
-
2
1
  require 'bump'
3
2
  require 'spec_helper'
4
3
 
5
4
  describe Bump::Logger do
5
+ before :each do
6
+ @logger = Bump::Logger.new
7
+ end
8
+
9
+ describe '#log' do
10
+ it 'logs message' do
11
+ expect(@logger).to receive(:print).with('foo').once
12
+ expect(@logger).to receive(:print).with("\n").once
13
+
14
+ @logger.log 'foo'
15
+ end
16
+ end
17
+
18
+ describe '#green' do
19
+ it 'returns green text' do
20
+ expect(@logger.green('text')).to eq "\e[32mtext\e[0m"
21
+ end
22
+
23
+ it 'retruns no color text when the no_color option is true' do
24
+ @logger = Bump::Logger.new true
25
+
26
+ expect(@logger.green('text')).to eq 'text'
27
+ end
28
+ end
6
29
 
30
+ describe '#red' do
31
+ it 'returns red text' do
32
+ expect(@logger.red('text')).to eq "\e[31mtext\e[0m"
33
+ end
34
+ end
7
35
  end
@@ -2,4 +2,4 @@
2
2
  version: 1.2.3
3
3
  commit: 'chore(version): bump to v%.%.%'
4
4
  files:
5
- dummy.txt: v%.%.%
5
+ spec/fixture/dummy.txt: v%.%.%
@@ -0,0 +1,5 @@
1
+ ---
2
+ version: 3.0.0
3
+ commit: 'chore(version): bump to v%.%.%'
4
+ files:
5
+ dummy.txt: v%.%.%
@@ -0,0 +1,3 @@
1
+ version: 1.2.3
2
+ files:
3
+ spec/fixture/dummy.txt: foo%.%.%
@@ -0,0 +1,5 @@
1
+ ---
2
+ version: 1.2.3
3
+ commit: 'chore(version): bump to v%.%.%'
4
+ files:
5
+ spec/fixture/tmp_dummy.txt: v%.%.%
@@ -1,4 +1,3 @@
1
-
2
1
  require 'simplecov'
3
2
  require 'coveralls'
4
3
 
@@ -8,7 +7,5 @@ SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
8
7
  ]
9
8
 
10
9
  SimpleCov.start do
11
- add_filter '/spec/'
10
+ add_filter '/spec/'
12
11
  end
13
-
14
- #Coveralls.wear!
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bmp
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yoshiya Hinosawa
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-15 00:00:00.000000000 Z
11
+ date: 2016-05-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: slop
@@ -63,6 +63,7 @@ files:
63
63
  - ".bmp.yml"
64
64
  - ".editorconfig"
65
65
  - ".gitignore"
66
+ - ".rubocop.yml"
66
67
  - ".travis.yml"
67
68
  - Gemfile
68
69
  - Gemfile.lock
@@ -96,6 +97,9 @@ files:
96
97
  - spec/bump/domain/version_number_spec.rb
97
98
  - spec/bump/logger_spec.rb
98
99
  - spec/fixture/bmp.yml
100
+ - spec/fixture/bmp_invalid.yml
101
+ - spec/fixture/bmp_invalid_pattern.yml
102
+ - spec/fixture/bmp_tmp.yml
99
103
  - spec/fixture/dummy.txt
100
104
  - spec/spec_helper.rb
101
105
  homepage: https://github.com/kt3k/bump
@@ -134,5 +138,8 @@ test_files:
134
138
  - spec/bump/domain/version_number_spec.rb
135
139
  - spec/bump/logger_spec.rb
136
140
  - spec/fixture/bmp.yml
141
+ - spec/fixture/bmp_invalid.yml
142
+ - spec/fixture/bmp_invalid_pattern.yml
143
+ - spec/fixture/bmp_tmp.yml
137
144
  - spec/fixture/dummy.txt
138
145
  - spec/spec_helper.rb