eac_ruby_gems_utils 0.8.0 → 0.9.0
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
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f10dcfe737d3c84df10c25a0fa82bcb7b49828b0470e83781863dbcd51ea07b2
|
4
|
+
data.tar.gz: '01930655004cdc2b58fe3691a9f781d40ef3261cbbfce8569eb58962c8e4a5e6'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aea3df2c2992bcaf24684910e043eda8ce4fefd6b25ee3f9111ab7d7388df010c2dc1c0923a9f4e79ff699472e76f09737d7327108c53924c8d201844a1d865d
|
7
|
+
data.tar.gz: d04bb3e97d4a7c9d66a513fce6c63573f61f0b896f2edfcfc50a7bff3231a861bc34d5c86e9f502db1637a8244c433922fbd748e54c2f1c6550681f0408c3187
|
@@ -1,6 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require 'eac_ruby_utils/core_ext'
|
4
|
+
require 'eac_ruby_utils/fs/logs'
|
4
5
|
require 'eac_ruby_utils/fs_cache'
|
5
6
|
require 'eac_ruby_utils/listable'
|
6
7
|
require 'eac_ruby_utils/on_clean_ruby_environment'
|
@@ -27,20 +28,16 @@ module EacRubyGemsUtils
|
|
27
28
|
self.class.name.demodulize.gsub(/Test\z/, '')
|
28
29
|
end
|
29
30
|
|
30
|
-
def stdout_cache
|
31
|
-
root_cache.child('stdout')
|
32
|
-
end
|
33
|
-
|
34
|
-
def stderr_cache
|
35
|
-
root_cache.child('stderr')
|
36
|
-
end
|
37
|
-
|
38
31
|
def to_s
|
39
32
|
"#{gem}[#{name}]"
|
40
33
|
end
|
41
34
|
|
42
35
|
private
|
43
36
|
|
37
|
+
def logs_uncached
|
38
|
+
::EacRubyUtils::Fs::Logs.new.add(:stdout).add(:stderr)
|
39
|
+
end
|
40
|
+
|
44
41
|
def result_uncached
|
45
42
|
return RESULT_NONEXISTENT unless elegible?
|
46
43
|
|
@@ -53,8 +50,8 @@ module EacRubyGemsUtils
|
|
53
50
|
|
54
51
|
def exec_run_with_log
|
55
52
|
r = exec_run
|
56
|
-
|
57
|
-
|
53
|
+
logs[:stdout].write(r[:stdout])
|
54
|
+
logs[:stderr].write(r[:stderr])
|
58
55
|
r[:exit_code].zero?
|
59
56
|
end
|
60
57
|
|
@@ -27,6 +27,12 @@ module EacRubyGemsUtils
|
|
27
27
|
decorated_gems.flat_map(&:tests)
|
28
28
|
end
|
29
29
|
|
30
|
+
def clear_logs
|
31
|
+
all_tests.each do |test|
|
32
|
+
test.logs.remove_all
|
33
|
+
end
|
34
|
+
end
|
35
|
+
|
30
36
|
def prepare_all_gems
|
31
37
|
infom 'Preparing all gems...'
|
32
38
|
decorated_gems.each(&:prepare)
|
@@ -47,8 +53,7 @@ module EacRubyGemsUtils
|
|
47
53
|
warn 'Some test did not pass:'
|
48
54
|
failed_tests.each do |test|
|
49
55
|
infov ' * Test', test
|
50
|
-
|
51
|
-
infov ' * STDERR', test.stderr_cache.content_path
|
56
|
+
info test.logs.truncate_all
|
52
57
|
end
|
53
58
|
else
|
54
59
|
success 'All tests passed'
|
@@ -60,6 +65,8 @@ module EacRubyGemsUtils
|
|
60
65
|
prepare_all_gems
|
61
66
|
test_all_gems
|
62
67
|
final_results_banner
|
68
|
+
ensure
|
69
|
+
clear_logs
|
63
70
|
end
|
64
71
|
|
65
72
|
def start_banner
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: eac_ruby_gems_utils
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.9.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Esquilo Azul Company
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-03-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: eac_ruby_utils
|
@@ -97,7 +97,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
97
97
|
- !ruby/object:Gem::Version
|
98
98
|
version: '0'
|
99
99
|
requirements: []
|
100
|
-
rubygems_version: 3.0.
|
100
|
+
rubygems_version: 3.0.9
|
101
101
|
signing_key:
|
102
102
|
specification_version: 4
|
103
103
|
summary: Utilities for Ruby gems development.
|