xcpretty-travis-formatter 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 +4 -4
- data/lib/travis_formatter.rb +10 -6
- 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: 871979916c4bf2d87e96fb3f6250f44d046c0868
|
4
|
+
data.tar.gz: ffc5ceb5e2f9174b26401da146c1bbb7894bc9a6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d75a68238ca422040a7792219428f92e4bcdd6b22d0b5761366eac16a9faa36df8c64349f442676966f9fa4e95ca23e8322dfe36b8d213f9d561e7878b8406ed
|
7
|
+
data.tar.gz: 98887aa7be0372514a80aca660cfb88741bea498c15393f88c5fcf14b6803618c04a9739aab917f1c118dab0e7cdf81b39cce61d9be58175540814ed77437d4a
|
data/lib/travis_formatter.rb
CHANGED
@@ -4,33 +4,37 @@ class TravisFormatter < XCPretty::Simple
|
|
4
4
|
def open_fold(text)
|
5
5
|
return if text == @open_fold
|
6
6
|
close_fold(@open_fold) if @open_fold
|
7
|
-
|
7
|
+
print "travis_fold:start:#{text}\r"
|
8
8
|
@open_fold = text
|
9
9
|
end
|
10
10
|
|
11
11
|
def close_fold(text)
|
12
|
-
|
12
|
+
print "travis_fold:end:#{text}\r"
|
13
13
|
@open_fold = nil
|
14
14
|
end
|
15
15
|
|
16
16
|
def format_build_target(target, project, configuration)
|
17
|
-
open_fold("Build
|
17
|
+
open_fold("Build")
|
18
18
|
super
|
19
19
|
end
|
20
20
|
|
21
21
|
def format_clean_target(project, target, configuration)
|
22
|
-
open_fold("Clean
|
22
|
+
open_fold("Clean")
|
23
23
|
super
|
24
24
|
end
|
25
25
|
|
26
26
|
def format_test_run_started(name)
|
27
|
-
open_fold(name)
|
27
|
+
open_fold("Tests-#{scrub(name)}")
|
28
28
|
super
|
29
29
|
end
|
30
30
|
|
31
31
|
def format_test_run_finished(name, time)
|
32
|
+
close_fold("Tests-#{scrub(name)}")
|
32
33
|
super
|
33
|
-
|
34
|
+
end
|
35
|
+
|
36
|
+
def scrub(text)
|
37
|
+
text.gsub(/\s/,"_").split(".").first
|
34
38
|
end
|
35
39
|
end
|
36
40
|
|