guard-phpunit2 0.2.2 → 0.2.3
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.
- checksums.yaml +4 -4
- data/lib/guard/phpunit2/notifier.rb +2 -3
- data/lib/guard/phpunit2/runner.rb +3 -5
- data/lib/guard/phpunit2/version.rb +1 -1
- data/lib/guard/phpunit2.rb +2 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 29049fcae5b8a04752ba78a2a8e4b99299fa282e
|
4
|
+
data.tar.gz: 5d74a651906f7d51085ca82faf7b0211a0967464
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a274812dc59206fc0f1edc7f2c7c654e35868477e989c513d29becd82f62f2a1c21ecb9eb69c64caa99a553a6513da9d5ccb2850cf4a43c4727c8bcb47a0e140
|
7
|
+
data.tar.gz: d7a39c5e0467acb4ae0a2298d5f4a4d12848e14ea1c11fc0411a3fee756c610e534613204678ffbe4f557e6fcd8686069ebda77550f865188ea8885e2cb8c3c2
|
@@ -53,10 +53,9 @@ module Guard
|
|
53
53
|
# @return [Symbol] the image symbol
|
54
54
|
#
|
55
55
|
def image(results)
|
56
|
-
|
57
|
-
when results[:failures] + results[:errors] > 0
|
56
|
+
if results[:failures] + results[:errors] > 0
|
58
57
|
:failed
|
59
|
-
|
58
|
+
elsif results[:pending] > 0
|
60
59
|
:pending
|
61
60
|
else
|
62
61
|
:success
|
@@ -12,11 +12,11 @@ module Guard
|
|
12
12
|
|
13
13
|
# The exittcode phpunit returns when the tests contain failures
|
14
14
|
#
|
15
|
-
PHPUNIT_FAILURES_EXITCODE =
|
15
|
+
PHPUNIT_FAILURES_EXITCODE = 3
|
16
16
|
|
17
17
|
# The exittcode phpunit returns when the tests contain errors
|
18
18
|
#
|
19
|
-
PHPUNIT_ERRORS_EXITCODE =
|
19
|
+
PHPUNIT_ERRORS_EXITCODE = 4
|
20
20
|
|
21
21
|
# Runs the PHPUnit tests and displays notifications
|
22
22
|
# about the results.
|
@@ -72,7 +72,7 @@ module Guard
|
|
72
72
|
end
|
73
73
|
|
74
74
|
# print the output to the terminal
|
75
|
-
|
75
|
+
puts output
|
76
76
|
|
77
77
|
# return false in case the system call fails with no status!
|
78
78
|
return false if $?.nil?
|
@@ -102,7 +102,6 @@ module Guard
|
|
102
102
|
# @param (see #run)
|
103
103
|
#
|
104
104
|
def notify_results(output, options)
|
105
|
-
return if options[:notification] == false
|
106
105
|
results = Formatter.parse_output(output)
|
107
106
|
Notifier.notify_results(results)
|
108
107
|
end
|
@@ -112,7 +111,6 @@ module Guard
|
|
112
111
|
# @param (see #run)
|
113
112
|
#
|
114
113
|
def notify_failure(options)
|
115
|
-
return if options[:notification] == false
|
116
114
|
Notifier.notify('Failed! Check the console', :title => 'PHPUnit results', :image => :failed)
|
117
115
|
end
|
118
116
|
|
data/lib/guard/phpunit2.rb
CHANGED