grntest 1.3.9 → 1.4.4
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/doc/text/news.md +35 -0
- data/lib/grntest/execution-context.rb +15 -0
- data/lib/grntest/executors/base-executor.rb +21 -2
- data/lib/grntest/test-runner.rb +2 -0
- data/lib/grntest/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9733d4f25a25296b60589e7c0328872954955799278fa0194a82c279c92c5f84
|
4
|
+
data.tar.gz: 653013c00c4f38eb2c9d41edf5963fd4ccafe6a491672e5afd6d4b4b7b8dad15
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f395c3c2eb4949842e4eefcf933ca13a71662d3b7f192e33441a91c8b69bc7a9edad21602743cb069f7247c4675ec0fc3baa738a70211bbe8963fb594f853d95
|
7
|
+
data.tar.gz: 6075f8e1009aff8baf34824cb125468b45809ea8465077e27d7d80b10864a5ebe8790abda81336a2da220840583c97f53e417e9f7139da718bd2706140860ded
|
data/doc/text/news.md
CHANGED
@@ -1,5 +1,40 @@
|
|
1
1
|
# News
|
2
2
|
|
3
|
+
## 1.4.4: 2020-07-18
|
4
|
+
|
5
|
+
### Improvements
|
6
|
+
|
7
|
+
* Added support for detecting backtrace log for MinGW build.
|
8
|
+
|
9
|
+
## 1.4.3: 2020-05-31
|
10
|
+
|
11
|
+
### Improvements
|
12
|
+
|
13
|
+
* Removed log normalization.
|
14
|
+
|
15
|
+
## 1.4.2: 2020-05-30
|
16
|
+
|
17
|
+
### Improvements
|
18
|
+
|
19
|
+
* Removed log level normalization.
|
20
|
+
|
21
|
+
* Added `require-platform` directive.
|
22
|
+
|
23
|
+
* Added support for normalizing IO open/close log message with
|
24
|
+
additional message.
|
25
|
+
|
26
|
+
## 1.4.1: 2020-05-30
|
27
|
+
|
28
|
+
### Improvements
|
29
|
+
|
30
|
+
* Added support for normalizing IO open/close log message.
|
31
|
+
|
32
|
+
## 1.4.0: 2020-05-16
|
33
|
+
|
34
|
+
### Improvements
|
35
|
+
|
36
|
+
* Added support for normalizing mruby's syntax error message.
|
37
|
+
|
3
38
|
## 1.3.9: 2020-05-09
|
4
39
|
|
5
40
|
### Improvements
|
@@ -37,6 +37,7 @@ module Grntest
|
|
37
37
|
attr_writer :suppress_backtrace
|
38
38
|
attr_writer :collect_query_log
|
39
39
|
attr_writer :debug
|
40
|
+
attr_accessor :platform
|
40
41
|
def initialize
|
41
42
|
@logging = true
|
42
43
|
@base_directory = Pathname(".")
|
@@ -66,6 +67,7 @@ module Grntest
|
|
66
67
|
@suppress_backtrace = true
|
67
68
|
@collect_query_log = false
|
68
69
|
@debug = false
|
70
|
+
@platform = guess_platform
|
69
71
|
end
|
70
72
|
|
71
73
|
def logging?
|
@@ -173,5 +175,18 @@ module Grntest
|
|
173
175
|
"so"
|
174
176
|
end
|
175
177
|
end
|
178
|
+
|
179
|
+
def guess_platform
|
180
|
+
case RUBY_PLATFORM
|
181
|
+
when /mingw|mswin/
|
182
|
+
"windows"
|
183
|
+
when /darwin/
|
184
|
+
"macos"
|
185
|
+
when /linux/
|
186
|
+
"linux"
|
187
|
+
else
|
188
|
+
"unknown"
|
189
|
+
end
|
190
|
+
end
|
176
191
|
end
|
177
192
|
end
|
@@ -374,6 +374,19 @@ module Grntest
|
|
374
374
|
@ignore_log_patterns.delete(pattern)
|
375
375
|
end
|
376
376
|
|
377
|
+
def execute_directive_require_platform(parser, line, content, options)
|
378
|
+
platform, = options
|
379
|
+
if platform.start_with?("!")
|
380
|
+
if @context.platform == platform[1..-1]
|
381
|
+
omit("require platform: #{platform} (#{@context.platform})")
|
382
|
+
end
|
383
|
+
else
|
384
|
+
if @context.platform != platform
|
385
|
+
omit("require platform: #{platform} (#{@context.platform})")
|
386
|
+
end
|
387
|
+
end
|
388
|
+
end
|
389
|
+
|
377
390
|
def execute_directive(parser, line, content)
|
378
391
|
command, *options = Shellwords.split(content)
|
379
392
|
case command
|
@@ -421,6 +434,8 @@ module Grntest
|
|
421
434
|
execute_directive_add_ignore_log_pattern(parser, line, content, options)
|
422
435
|
when "remove-ignore-log-pattern"
|
423
436
|
execute_directive_remove_ignore_log_pattern(parser, line, content, options)
|
437
|
+
when "require-platform"
|
438
|
+
execute_directive_require_platform(parser, line, content, options)
|
424
439
|
else
|
425
440
|
log_input(line)
|
426
441
|
log_error("#|e| unknown directive: <#{command}>")
|
@@ -535,8 +550,10 @@ module Grntest
|
|
535
550
|
end
|
536
551
|
next if thread_log_message?(entry.message)
|
537
552
|
next if ignore_log_message?(entry.message)
|
538
|
-
|
539
|
-
|
553
|
+
log_level = entry.log_level
|
554
|
+
formatted_log_level = format_log_level(log_level)
|
555
|
+
message = entry.message
|
556
|
+
important_messages << "\#|#{formatted_log_level}| #{message}"
|
540
557
|
end
|
541
558
|
important_messages.join("\n")
|
542
559
|
end
|
@@ -604,6 +621,8 @@ module Grntest
|
|
604
621
|
true
|
605
622
|
when /\A\(unknown\):\d+:\d+: /
|
606
623
|
true
|
624
|
+
when /\A[\w.\\-]+:\d+:\d+: /
|
625
|
+
true
|
607
626
|
when /\A(?:groonga|groonga-httpd)
|
608
627
|
\((?:\+0x\h+|\w+\+0x\h+)?\)
|
609
628
|
\s
|
data/lib/grntest/test-runner.rb
CHANGED
data/lib/grntest/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: grntest
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kouhei Sutou
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2020-
|
12
|
+
date: 2020-07-17 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: diff-lcs
|