Skip to content

Commit

Permalink
Add complete mute example to README
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris Hunt committed Jan 19, 2014
1 parent 741d2de commit 8b95d31
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion README.md
Expand Up @@ -42,7 +42,7 @@ puts output
#=> Oops!
```

Or use it in your test suite:
Use it in your test suite to verify output:

```ruby
require 'mute'
Expand All @@ -60,6 +60,15 @@ describe MyLogger do
end
```

Or just mute stdout completely for the whole test suite:

```ruby
# spec/spec_helper.rb
require 'mute'

Mute::IO.capture_stdout
```

## Installation

```bash
Expand Down

0 comments on commit 8b95d31

Please sign in to comment.