rfc 0.1.1 → 0.2.0
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/README.md +4 -0
- data/lib/rfc/aif.rb +4 -1
- data/lib/rfc/rif.rb +3 -0
- data/lib/rfc/shared/brief_pending.rb +27 -0
- data/lib/rfc/version.rb +1 -1
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 04fa1dfc9002e8040bc882dd222a69b0847864554503999681e6937ddbf5c11e
|
4
|
+
data.tar.gz: 6990f5279ce8c11b17ef65fb9541dae403db4b129282f34e45e71dbc02b71ccb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c1121b9d6ddd02a216da1275d7c5024ced12b97c7ec0f7c59a9c408bed7d485e42afbbc6f56735e5559aa0f87c78d4743b5f9f0d7907088a9df83e167ce958f5
|
7
|
+
data.tar.gz: 7185313c51ac7aafb7e872f89b44cb3b08a3178eaca82a76bfb26ca4c37c1c656070c37a52b6c23db17caeb14432b82e15094be1bc94a7561ba277666b98a2aa
|
data/README.md
CHANGED
@@ -30,6 +30,8 @@ To enable memory and CPU statistics reporting, add to your `spec_helper.rb`:
|
|
30
30
|
|
31
31
|
Rfc::Rif.output_system_load = true
|
32
32
|
|
33
|
+
At the end of the run Aif lists up to the first 10 pending examples.
|
34
|
+
|
33
35
|
|
34
36
|
## Announce Formatter (Announce)
|
35
37
|
|
@@ -47,6 +49,8 @@ RSpec's documentation formatter does.
|
|
47
49
|
This is the announce formatter with insta-fail feature. It reports
|
48
50
|
failures as soon as they happen, after each example is executed.
|
49
51
|
|
52
|
+
At the end of the run Aif lists up to the first 10 pending examples.
|
53
|
+
|
50
54
|
|
51
55
|
## License
|
52
56
|
|
data/lib/rfc/aif.rb
CHANGED
@@ -1,12 +1,15 @@
|
|
1
|
+
require 'rfc/shared/brief_pending'
|
1
2
|
require 'rfc/announce'
|
2
3
|
|
3
4
|
module Rfc
|
4
5
|
class Aif < Announce
|
6
|
+
include Shared::BriefPending
|
7
|
+
|
5
8
|
RSpec::Core::Formatters.register self,
|
6
9
|
:example_group_started, :example_group_finished,
|
7
10
|
:start, :example_started,
|
8
11
|
:example_passed, :example_pending, :example_failed,
|
9
|
-
:dump_failures, :
|
12
|
+
:dump_summary, :dump_failures, :dump_pending
|
10
13
|
|
11
14
|
def start(notification)
|
12
15
|
@failed_count = 0
|
data/lib/rfc/rif.rb
CHANGED
@@ -1,9 +1,12 @@
|
|
1
1
|
require 'rspec/core'
|
2
2
|
require 'rfc/cpu_time_averager'
|
3
|
+
require 'rfc/shared/brief_pending'
|
3
4
|
RSpec::Support.require_rspec_core "formatters/base_text_formatter"
|
4
5
|
|
5
6
|
module Rfc
|
6
7
|
class Rif < RSpec::Core::Formatters::BaseTextFormatter
|
8
|
+
include Shared::BriefPending
|
9
|
+
|
7
10
|
RSpec::Core::Formatters.register self,
|
8
11
|
:message, :dump_summary, :dump_failures, :dump_pending, :seed,
|
9
12
|
:example_passed, :example_pending, :example_failed
|
@@ -0,0 +1,27 @@
|
|
1
|
+
module Rfc
|
2
|
+
module Shared
|
3
|
+
module BriefPending
|
4
|
+
|
5
|
+
def dump_pending(notification)
|
6
|
+
return if notification.pending_examples.empty?
|
7
|
+
|
8
|
+
formatted = "\nPending: (Failures listed here are expected and do not affect your suite's status)\n".dup
|
9
|
+
|
10
|
+
pending_notifications = notification.pending_notifications
|
11
|
+
colorizer = ::RSpec::Core::Formatters::ConsoleCodes
|
12
|
+
|
13
|
+
pending_notifications.first(10).each_with_index do |notification, index|
|
14
|
+
formatted << notification.fully_formatted(index.next, colorizer)
|
15
|
+
end
|
16
|
+
|
17
|
+
if pending_notifications.length > 10
|
18
|
+
formatted << colorizer.wrap(
|
19
|
+
"\n+ #{pending_notifications.length-10} more pending examples",
|
20
|
+
:yellow)
|
21
|
+
end
|
22
|
+
|
23
|
+
output.puts(formatted)
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
data/lib/rfc/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rfc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Oleg Pudeyev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-04-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec-core
|
@@ -38,6 +38,7 @@ files:
|
|
38
38
|
- lib/rfc/cpu_time_averager.rb
|
39
39
|
- lib/rfc/rif.rb
|
40
40
|
- lib/rfc/riff.rb
|
41
|
+
- lib/rfc/shared/brief_pending.rb
|
41
42
|
- lib/rfc/version.rb
|
42
43
|
homepage: https://github.com/p-mongo/rfc
|
43
44
|
licenses:
|
@@ -62,5 +63,5 @@ requirements: []
|
|
62
63
|
rubygems_version: 3.1.2
|
63
64
|
signing_key:
|
64
65
|
specification_version: 4
|
65
|
-
summary: rfc-0.
|
66
|
+
summary: rfc-0.2.0
|
66
67
|
test_files: []
|