cucumber_growlnotify 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/README.rdoc +8 -14
- data/VERSION +1 -1
- data/cucumber_growlnotify.gemspec +3 -1
- data/lib/cucumber_growlnotify.rb +12 -3
- data/resources/fail.png +0 -0
- data/resources/success.png +0 -0
- metadata +4 -2
data/README.rdoc
CHANGED
@@ -1,19 +1,13 @@
|
|
1
1
|
= cucumber_growlnotify
|
2
2
|
|
3
|
-
|
3
|
+
This gem notifies through growl that your cucumber tests are passing or not
|
4
4
|
|
5
|
-
==
|
6
|
-
|
7
|
-
* Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet
|
8
|
-
* Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it
|
9
|
-
* Fork the project
|
10
|
-
* Start a feature/bugfix branch
|
11
|
-
* Commit and push until you are happy with your contribution
|
12
|
-
* Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.
|
13
|
-
* Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.
|
5
|
+
== Installing
|
14
6
|
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
7
|
+
1. Install Growl
|
8
|
+
2. Install 'growlnotify' in the 'Extras' package in Growl installer
|
9
|
+
3. Add gem 'cucumber_growlnotify' to your projects Gemfile
|
10
|
+
4. Configure in System Preferences - Growl - Network
|
11
|
+
5. Check "Listen for incoming notifications" and "Allow remote application registration"
|
12
|
+
6. Run your cucumber tests with --format Cucumber::Formatter::Growl
|
19
13
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.2
|
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{cucumber_growlnotify}
|
8
|
-
s.version = "0.1.
|
8
|
+
s.version = "0.1.2"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Rodrigo Oliveira"]
|
@@ -26,6 +26,8 @@ Gem::Specification.new do |s|
|
|
26
26
|
"VERSION",
|
27
27
|
"cucumber_growlnotify.gemspec",
|
28
28
|
"lib/cucumber_growlnotify.rb",
|
29
|
+
"resources/fail.png",
|
30
|
+
"resources/success.png",
|
29
31
|
"test/helper.rb",
|
30
32
|
"test/test_cucumber_growlnotify.rb"
|
31
33
|
]
|
data/lib/cucumber_growlnotify.rb
CHANGED
@@ -12,6 +12,11 @@ module Cucumber
|
|
12
12
|
include Gherkin::Formatter::Escaping
|
13
13
|
attr_writer :indent
|
14
14
|
attr_reader :step_mother
|
15
|
+
|
16
|
+
IMAGES = {
|
17
|
+
:fail => File.dirname(__FILE__) + "/../resources/fail.png",
|
18
|
+
:success => File.dirname(__FILE__) + "/../resources/success.png"
|
19
|
+
}
|
15
20
|
|
16
21
|
def initialize(step_mother, path_or_io, options)
|
17
22
|
@step_mother, @io, @options = step_mother, ensure_io(path_or_io, "pretty"), options
|
@@ -227,8 +232,8 @@ module Cucumber
|
|
227
232
|
@prefixes[status]
|
228
233
|
end
|
229
234
|
|
230
|
-
def growl(title, msg, pri=0, sticky="")
|
231
|
-
system "growlnotify -p 0 -n '#{title}' -m '#{msg}' #{title}"
|
235
|
+
def growl(title, msg, image, pri=0, sticky="")
|
236
|
+
system "growlnotify -p 0 -n '#{title}' --image #{image} -m '#{msg}' #{title}"
|
232
237
|
end
|
233
238
|
|
234
239
|
def print_summary(features)
|
@@ -236,7 +241,11 @@ module Cucumber
|
|
236
241
|
print_snippets(@options)
|
237
242
|
print_passing_wip(@options)
|
238
243
|
message = @passed.to_s + " steps passed \n" + @failure.to_s + " steps failed"
|
239
|
-
|
244
|
+
image = IMAGES[:success]
|
245
|
+
if (@failure > 0)
|
246
|
+
image = IMAGES[:fail]
|
247
|
+
end
|
248
|
+
growl('Cucumber', message, image)
|
240
249
|
end
|
241
250
|
end
|
242
251
|
end
|
data/resources/fail.png
ADDED
Binary file
|
Binary file
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: cucumber_growlnotify
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.1.
|
5
|
+
version: 0.1.2
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Rodrigo Oliveira
|
@@ -65,6 +65,8 @@ files:
|
|
65
65
|
- VERSION
|
66
66
|
- cucumber_growlnotify.gemspec
|
67
67
|
- lib/cucumber_growlnotify.rb
|
68
|
+
- resources/fail.png
|
69
|
+
- resources/success.png
|
68
70
|
- test/helper.rb
|
69
71
|
- test/test_cucumber_growlnotify.rb
|
70
72
|
has_rdoc: true
|
@@ -81,7 +83,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
81
83
|
requirements:
|
82
84
|
- - ">="
|
83
85
|
- !ruby/object:Gem::Version
|
84
|
-
hash:
|
86
|
+
hash: 1477632336689089651
|
85
87
|
segments:
|
86
88
|
- 0
|
87
89
|
version: "0"
|