table_print 1.5.6 → 1.5.7

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
- SHA1:
3
- metadata.gz: 2f888ea5f3cd53aae3450eda4e53f9bd649a940a
4
- data.tar.gz: eaee7c7975d8b875a5a13290a89e1eca4797cbd2
2
+ SHA256:
3
+ metadata.gz: 4d550bded70ef9a5ae903bdf98d2436d282ef8d89bf760dd65c0a90476131bb4
4
+ data.tar.gz: 858aee5efcc4d4ce91c0834cf215cb29e4899964d4bc4d3c624c49c9902b592d
5
5
  SHA512:
6
- metadata.gz: fcb84a8749506b7a8de69471157e56f0584ce3183c644df5e7c9bcdac6b7b30220b4baf9cf6b1f6f473b75ec924fa982167ce5888ae544927a2d867090613627
7
- data.tar.gz: 433a4425650c26e68452b63edcc014c8018cf90cdf036972e130720fffa0b9120d8e4fbc83d182a99a191a0f1216d74ef2428adf42c10b72f4ab712a5a6bdc74
6
+ metadata.gz: f7980699dada79051fdfbb5611815377eebc3200745c814401ee24955daa7d6d1d2838a72da1f942e9eca64d926974d2d044955067548a3e10b7a1be48c00e4c
7
+ data.tar.gz: 7f8eb1af627f5efc816d2751be6bc641cdca8ae74aab482e56af936266b83158d6d5eebbadf66cd48a508f974635200c045cfeafc2e8f7ba57dfee20a28cb5ce
@@ -1,9 +1,9 @@
1
1
  language: ruby
2
2
  rvm:
3
- - 2.0
4
- - 2.2.4
3
+ - 2.4
4
+ - 2.5
5
+ - 2.6
6
+ - 2.7
5
7
  - jruby-18mode
6
8
  - jruby-19mode
7
- - rbx-2
8
- - ree
9
9
 
@@ -1,6 +1,6 @@
1
1
  = table_print
2
2
 
3
- {<img src="https://travis-ci.org/arches/table_print.png?branch=master" />}[http://travis-ci.org/arches/table_print]
3
+ {<img src="https://travis-ci.org/arches/table_print.svg?branch=master" />}[http://travis-ci.org/arches/table_print]
4
4
  {<img src="https://codeclimate.com/github/arches/table_print.png" />}[https://codeclimate.com/github/arches/table_print]
5
5
 
6
6
  TablePrint shows objects in nicely formatted columns for easy reading. It even lets you nest other tables
@@ -87,7 +87,7 @@ When /table_print ([\w\.:]*)$/ do |klass|
87
87
  end
88
88
 
89
89
  Then /^the output should contain$/ do |string|
90
- output = @r.lines.to_a
90
+ output = @r.each_line.to_a
91
91
 
92
92
  output.zip(string.split("\n")).each do |actual, expected|
93
93
  actual.gsub(/\s/m, "").split(//).sort.join.should == expected.gsub(" ", "").split(//).sort.join
@@ -51,7 +51,10 @@ module TablePrint
51
51
 
52
52
  def message
53
53
  return "Printed with config" if configged?
54
- Time.now - @start_time
54
+ (Time.now - @start_time).to_s
55
+ # the message is used to initiate Returnable
56
+ # whose argument is regarded in ruby 2.7.1 as string
57
+ # (ruby 2.7.1 calls ".includes?" method on this argument)
55
58
  end
56
59
 
57
60
  private
@@ -24,6 +24,6 @@ module TablePrint
24
24
 
25
25
  def inspect
26
26
  to_s
27
- end
27
+ end
28
28
  end
29
29
  end
@@ -221,8 +221,8 @@ module TablePrint
221
221
  formatters << FixedWidthFormatter.new(column_for(column_name).width)
222
222
 
223
223
  # successively apply the formatters for a column
224
- formatters.inject(value) do |value, formatter|
225
- formatter.format(value)
224
+ formatters.inject(value) do |inner_value, formatter|
225
+ formatter.format(inner_value)
226
226
  end
227
227
  end
228
228
 
@@ -1,4 +1,4 @@
1
1
  module TablePrint
2
- VERSION = "1.5.6"
2
+ VERSION = "1.5.7"
3
3
  end
4
4
 
@@ -25,8 +25,10 @@ describe TablePrint::Printer do
25
25
  end
26
26
 
27
27
  describe "message" do
28
- it "defaults to the time the print took" do
29
- Printer.new([]).message.should be_a Numeric
28
+ it "defaults to the time the print took, but in string" do
29
+ message = Printer.new([]).message
30
+ message.should be_a String
31
+ expect(message.to_f.to_s).to eq(message)
30
32
  end
31
33
 
32
34
  it "shows a warning if the printed objects have config" do
@@ -19,7 +19,7 @@ Gem::Specification.new do |gem|
19
19
  gem.require_paths = ["lib"]
20
20
 
21
21
  gem.add_development_dependency 'cat', '~> 0.2.1'
22
- gem.add_development_dependency 'cucumber', '~> 1.2.1'
22
+ gem.add_development_dependency 'cucumber', '~> 2.4.0'
23
23
  gem.add_development_dependency 'rspec', '~> 2.11.0'
24
24
  gem.add_development_dependency 'rake', '~> 0.9.2'
25
25
  end
metadata CHANGED
@@ -1,69 +1,69 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: table_print
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.6
4
+ version: 1.5.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Doyle
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-25 00:00:00.000000000 Z
11
+ date: 2020-06-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cat
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: 0.2.1
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.2.1
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: cucumber
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 1.2.1
33
+ version: 2.4.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
- version: 1.2.1
40
+ version: 2.4.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rspec
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ~>
45
+ - - "~>"
46
46
  - !ruby/object:Gem::Version
47
47
  version: 2.11.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: 2.11.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rake
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - ~>
59
+ - - "~>"
60
60
  - !ruby/object:Gem::Version
61
61
  version: 0.9.2
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - ~>
66
+ - - "~>"
67
67
  - !ruby/object:Gem::Version
68
68
  version: 0.9.2
69
69
  description: TablePrint turns objects into nicely formatted columns for easy reading.
@@ -74,10 +74,10 @@ executables: []
74
74
  extensions: []
75
75
  extra_rdoc_files: []
76
76
  files:
77
- - .document
78
- - .gitignore
79
- - .rspec
80
- - .travis.yml
77
+ - ".document"
78
+ - ".gitignore"
79
+ - ".rspec"
80
+ - ".travis.yml"
81
81
  - Gemfile
82
82
  - LICENSE.txt
83
83
  - README.rdoc
@@ -124,17 +124,16 @@ require_paths:
124
124
  - lib
125
125
  required_ruby_version: !ruby/object:Gem::Requirement
126
126
  requirements:
127
- - - '>='
127
+ - - ">="
128
128
  - !ruby/object:Gem::Version
129
129
  version: '0'
130
130
  required_rubygems_version: !ruby/object:Gem::Requirement
131
131
  requirements:
132
- - - '>='
132
+ - - ">="
133
133
  - !ruby/object:Gem::Version
134
134
  version: '0'
135
135
  requirements: []
136
- rubyforge_project:
137
- rubygems_version: 2.4.8
136
+ rubygems_version: 3.0.3
138
137
  signing_key:
139
138
  specification_version: 4
140
139
  summary: Turn objects into nicely formatted columns for easy reading