io-grab 0.0.1 → 0.0.2

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: 5241f1725ddbaf480263daeac6cc897f8cec46a1
4
- data.tar.gz: b2c1ca38783c61a6a259d261c22debcff9e0042e
3
+ metadata.gz: 173d96123e3eeae8ce25fd382dfaa8ca8163f9a8
4
+ data.tar.gz: 7b91df293a70697567aaba63576a6f890d00972f
5
5
  SHA512:
6
- metadata.gz: c3ab6aaba8e5fda57a7d153abde454c1f98570e0252a2ac40aad89d15b2081db785d0f1ff13ff2ca8be91372e1a77672ee60ab711f6789028b6b7abd3e04ef6f
7
- data.tar.gz: 72bdb3967fe09c9dbcdf80e5acd6574806a860044b1404c22717bbdf266aca490d40f1fc82be977a5b983516e7e45b9755bd3425fdb3b51f131b11c50ecf2730
6
+ metadata.gz: 88c30bea1ce4b4062c76d22d48e62e4c4892493944b437202e9d4194746563d5f764570ee88ca12691eb0e784bd8cf5b20cec819739899d6ca5980020b69646a
7
+ data.tar.gz: 886d6607a36c22611810d45bd931fc504012b2eb155b606588880438579544101ea3019e4111489627d4a63ec15ce4d49c13f8447c50dbe475dd737a425bb8cd
data/README.md CHANGED
@@ -6,7 +6,7 @@ Capture IO writes.
6
6
 
7
7
  Add this line to your application's Gemfile:
8
8
 
9
- gem 'io-grab'
9
+ gem 'io-grab', require: false
10
10
 
11
11
  And then execute:
12
12
 
@@ -21,18 +21,22 @@ Or install it yourself as:
21
21
  io-grab adds #grab method to IO. (It also extends StringIO for consistency, even though it isn't really an IO.)
22
22
  You can use this method to temporarily redirect writes to the object to a string, ie. for later examination.
23
23
 
24
- require 'io/grab'
24
+ ```ruby
25
+ require 'io/grab'
25
26
 
26
- STDOUT.grab { puts "foo" }
27
- # => "foo\n"
27
+ STDOUT.grab { puts "foo" }
28
+ # _ == "foo\n"
29
+ ```
28
30
 
29
31
  This is particularly useful for testing, eg. to check for expected messages.
30
32
 
31
- describe "Kernel#puts" do
32
- it "adds a newline at the end" do
33
- STDOUT.grab { puts "foo" }.should =~ /\n\z/
34
- end
35
- end
33
+ ```ruby
34
+ describe "Kernel#puts" do
35
+ it "adds a newline at the end" do
36
+ STDOUT.grab { puts "foo" }.should =~ /\n\z/
37
+ end
38
+ end
39
+ ```
36
40
 
37
41
  ## Contributing
38
42
 
@@ -1,4 +1,5 @@
1
1
  require "io/grab/version"
2
+ require 'stringio'
2
3
 
3
4
  class IO
4
5
  module Grab
@@ -1,5 +1,5 @@
1
1
  class IO
2
2
  module Grab
3
- VERSION = "0.0.1"
3
+ VERSION = "0.0.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,55 +1,55 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: io-grab
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rafał Rzepecki
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-06-21 00:00:00.000000000 Z
11
+ date: 2015-09-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.3'
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: '1.3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
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: rspec
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: 'Adds #grab method to IO, which permits capturing all writes to that
@@ -60,8 +60,8 @@ executables: []
60
60
  extensions: []
61
61
  extra_rdoc_files: []
62
62
  files:
63
- - .gitignore
64
- - .kateproject
63
+ - ".gitignore"
64
+ - ".kateproject"
65
65
  - Gemfile
66
66
  - LICENSE.txt
67
67
  - README.md
@@ -80,19 +80,20 @@ require_paths:
80
80
  - lib
81
81
  required_ruby_version: !ruby/object:Gem::Requirement
82
82
  requirements:
83
- - - '>='
83
+ - - ">="
84
84
  - !ruby/object:Gem::Version
85
85
  version: '0'
86
86
  required_rubygems_version: !ruby/object:Gem::Requirement
87
87
  requirements:
88
- - - '>='
88
+ - - ">="
89
89
  - !ruby/object:Gem::Version
90
90
  version: '0'
91
91
  requirements: []
92
92
  rubyforge_project:
93
- rubygems_version: 2.0.0.rc.2
93
+ rubygems_version: 2.4.8
94
94
  signing_key:
95
95
  specification_version: 4
96
96
  summary: Capture IO writes
97
97
  test_files:
98
98
  - spec/io-grab_spec.rb
99
+ has_rdoc: