varar-minitest 0.8.1 → 0.9.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/lib/varar/minitest.rb +8 -4
- metadata +4 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 1fcf220dd813224315d12f1014af95780aff0507c1e38decb77b8a0a944dbf60
|
|
4
|
+
data.tar.gz: 3aa4d61f25c245784041edc99df6058d6c710dc4b0970b74db438b42a5f74f65
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e958f0dee52a659bebc1d0edfa9fddac087f315ec2f844b8af90fe9638f460061196a77739352901f13066d734d11b42a5a6209a6e99caed5693cb07bf65cdaf
|
|
7
|
+
data.tar.gz: 47ac4646ba685aa38b61cfbdf415c905d587f15382526bd5b11c0c4ab4826b2196405c62fca849e945191708ddb404ff91b64d7780648a3df4da05cc52d5cf8b
|
data/lib/varar/minitest.rb
CHANGED
|
@@ -12,7 +12,7 @@ module Varar
|
|
|
12
12
|
# require "varar/minitest"
|
|
13
13
|
# Varar::Minitest.generate_tests
|
|
14
14
|
module Minitest
|
|
15
|
-
VERSION = '0.
|
|
15
|
+
VERSION = '0.9.0'
|
|
16
16
|
|
|
17
17
|
module_function
|
|
18
18
|
|
|
@@ -81,8 +81,9 @@ module Varar
|
|
|
81
81
|
klass = Class.new(::Minitest::Test)
|
|
82
82
|
seen = Hash.new(0)
|
|
83
83
|
pairs.each do |example, run|
|
|
84
|
-
|
|
85
|
-
|
|
84
|
+
# The example's name (ADR 0017) — unique within the oath, but two names
|
|
85
|
+
# can still collapse to one identifier, so number those.
|
|
86
|
+
stem = identifier(example.name)
|
|
86
87
|
idx = seen[stem]
|
|
87
88
|
seen[stem] += 1
|
|
88
89
|
method_name = idx.zero? ? "test_#{stem}" : "test_#{stem}_#{idx}"
|
|
@@ -108,7 +109,10 @@ module Varar
|
|
|
108
109
|
end
|
|
109
110
|
end
|
|
110
111
|
|
|
111
|
-
|
|
112
|
+
# A paragraph that became an example (#120) is named on stderr when the
|
|
113
|
+
# baseline is rewritten — a notice, never a failure.
|
|
114
|
+
notify = ->(line) { $stderr.write("#{line}\n") }
|
|
115
|
+
Core::Drifts.reconcile_drift(store, rel, plan.doc, plan, update: update, notify: notify).each do |drift|
|
|
112
116
|
message = Core::Diagnostics.drift_detected(drift.name, drift.span).message
|
|
113
117
|
klass.define_method("test_var_drift_#{drift.line}") { raise ::Minitest::Assertion, message }
|
|
114
118
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: varar-minitest
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.9.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Aslak Hellesøy
|
|
@@ -29,14 +29,14 @@ dependencies:
|
|
|
29
29
|
requirements:
|
|
30
30
|
- - '='
|
|
31
31
|
- !ruby/object:Gem::Version
|
|
32
|
-
version: 0.
|
|
32
|
+
version: 0.9.0
|
|
33
33
|
type: :runtime
|
|
34
34
|
prerelease: false
|
|
35
35
|
version_requirements: !ruby/object:Gem::Requirement
|
|
36
36
|
requirements:
|
|
37
37
|
- - '='
|
|
38
38
|
- !ruby/object:Gem::Version
|
|
39
|
-
version: 0.
|
|
39
|
+
version: 0.9.0
|
|
40
40
|
description: 'Minitest adapter: one selectable test per Markdown example, with a drift
|
|
41
41
|
gate.'
|
|
42
42
|
email:
|
|
@@ -65,7 +65,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
65
65
|
- !ruby/object:Gem::Version
|
|
66
66
|
version: '0'
|
|
67
67
|
requirements: []
|
|
68
|
-
rubygems_version: 4.0.
|
|
68
|
+
rubygems_version: 4.0.20
|
|
69
69
|
specification_version: 4
|
|
70
70
|
summary: Markdown-native BDD — run Markdown oaths as Minitest tests
|
|
71
71
|
test_files: []
|