wrong 0.4.0-java → 0.4.1-java

Sign up to get free protection for your applications and to get access to all the features.
data/README.markdown CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  ## Abstract ##
6
6
 
7
- Wrong provides a general assert method that takes a predicate block. Assertion failure messages are rich in detail. The Wrong idea is to replace all those countless assert\_this, assert\_that, should\_something library methods which only exist to give a more useful failure message than "assertion failed". Wrong replaces all of them in one fell swoop, since if you can write it in Ruby, Wrong can make a sensible failure message out of it.
7
+ Wrong provides a general assert method that takes a predicate block. Assertion failure messages are rich in detail. The Wrong idea is to replace all those countless `assert\_this`, `assert\_that`, `should\_something` library methods which only exist to give a failure message that's not simply "assertion failed". Wrong replaces all of them in one fell swoop, since if you can write it in Ruby, Wrong can make a sensible failure message out of it.
8
8
 
9
9
  We'd very much appreciate feedback and bug reports. There are plenty of things left to be done to make the results look uniformly clean and beautiful. We want your feedback, and especially to give us cases where either it blows up or the output is ugly or uninformative.
10
10
 
@@ -16,11 +16,7 @@ Inspired by [assert { 2.0 }](http://assert2.rubyforge.org/) but rewritten from s
16
16
 
17
17
  gem install wrong
18
18
 
19
- Under JRuby, the above may cause errors; if so, then try
20
-
21
- gem install wrong-jruby
22
-
23
- which untangles some dependencies.
19
+ We have deployed gems for both Ruby and JRuby; if you get dependency issues on your platform, please let us know what Ruby interpreter and version you're using and what errors you get, and we'll try to track it down.
24
20
 
25
21
  ## Usage ##
26
22
 
@@ -139,13 +135,14 @@ or this
139
135
  ? The Wrong way has the advantage of being plain, transparent Ruby code, not an awkward DSL that moves "equal" out of its natural place between the comparands. Plus, WYSIWYG! You know just from looking at it that "equal" means `==`, not `eql?` or `===` or `=~`.
140
136
 
141
137
  Moreover, much like TDD itself, Wrong encourages you to write cleaner code. If your assertion messages are not clear and "Englishy", then maybe it's time for you to refactor a bit -- extract an informatively named variable or method, maybe push some function onto its natural object *a la* the [Law of Demeter](http://en.wikipedia.org/wiki/Law_of_Demeter)...
138
+ Also, try not to call any methods with side effects inside an assert. In addition to being bad form, this can cause messed-up failure messages, since the side effects may occur several times in the process of building the message.
142
139
 
143
140
  Wrong also lets you put the expected and actual values in any order you want! Consider the failure messages for
144
141
 
145
142
  assert { current_user == "joe" } # => Expected (current_user == "joe") but current_user is "fred"
146
143
  assert { "joe" == current_user } # => Expected ("joe" == current_user) but current_user is "fred"
147
144
 
148
- You get just the information you want, and none you don't want. At least, that's the plan! :-)
145
+ You get all the information you want, and none you don't want. At least, that's the plan! :-)
149
146
 
150
147
  ## Algorithm ##
151
148
 
@@ -153,16 +150,18 @@ So wait a second. How do we do it? Doesn't Ruby have [poor support for AST intro
153
150
 
154
151
  Before you get your knickers in a twist about how this is totally unacceptable because it doesn't support this or that use case, here are our caveats and excuses:
155
152
 
156
- * It works! Tested in 1.8.6, 1.8.7, 1.9.1, and 1.9.2-rc2. (Thank you, [rvm](http://rvm.beginrescueend.com/)!)
153
+ * It works! Tested in MRI 1.8.6, 1.8.7, 1.9.1, 1.9.2, and JRuby 1.5.3. (Thank you, [rvm](http://rvm.beginrescueend.com/)!)
157
154
  * Your code needs to be in a file.
158
155
  * If you're developing Ruby code without saving it to a mounted disk, then sorry, Wrong is not right for you.
159
- * We monkey-patch IRB so if you do `irb -rwrong` it'll save off your session in a place Wrong can read it.
156
+ * We monkey-patch IRB so if you do `irb -rwrong` it'll save off your session in memory where Wrong can read it.
157
+ * It'd be nice if it could work inside a `-e` block but as far as we can tell, there's no way to grab that `-e` code from inside Ruby.
160
158
  * It's a development-time testing library, not a production runtime library, so there are no security or filesystem issues.
161
159
  * `eval` isn't evil, it's just misunderstood.
162
160
  * It makes a few assumptions about the structure of your code, leading to some restrictions:
163
- * You can't have more than one call to `assert` per line. (This should not be a problem since even if you're nesting asserts for some bizarre reason, we assume you know where your Return key is. And actually, technically you can put two asserts on a line, but it always describes the first one it sees, which means that if the second one executes, its failure message will be incorrect or broken.)
161
+ * You can't have more than one call to `assert` per line. (This should not be a problem since even if you're nesting asserts for some bizarre reason, we assume you know where your Return key is.)
164
162
  * You can't use metaprogramming to write your assert blocks.
165
- * All variables and methods must be available in the binding of the assertion block.
163
+ * All variables and methods must be available in the binding of the assert block.
164
+ * Passing a proc around and eventually calling assert on it might not work in some Ruby implementations.
166
165
 
167
166
  ## Adapters ##
168
167
 
@@ -172,9 +171,9 @@ Currently we support
172
171
 
173
172
  * Test::Unit - `require 'wrong/adapters/test_unit'`
174
173
  * Minitest - `require 'wrong/adapters/minitest'`
175
- * RSpec - `require 'wrong/adapters/rspec'`
174
+ * RSpec - `require 'wrong/adapters/rspec'` (now supports both 1.3 and 2.0)
176
175
 
177
- To use these, put the appropriate `require` in your helper; it should extend the framework enough that you can use `assert { }` in your test cases without extra fussing around.
176
+ To use these, put the appropriate `require` in your helper, **after** requiring your test framework; it should extend the framework enough that you can use `assert { }` in your test cases without extra fussing around.
178
177
 
179
178
  ## Explanations ##
180
179
 
@@ -248,34 +247,52 @@ To use these formatters, you have to explicitly `require` them! You may also nee
248
247
 
249
248
  [Bug: turns out 'diff' and 'diff-lcs' are incompatible with each other. We're working on a fix.]
250
249
 
251
- ## Color ##
250
+ ## Config ##
251
+
252
+ These settings can either be set at runtime on the `Wrong.config` singleton, or inside a `.wrong` file in the current directory or a parent. In the `.wrong` file just pretend every line is preceded with `Wrong.config.` -- e.g. if there's a setting called `ice_cream`, you can do any of these in your `.wrong` file
253
+
254
+ ice_cream # => Wrong.config[:ice_cream] => true
255
+ ice_cream = true # => Wrong.config[:ice_cream] => true
256
+ ice_cream = "vanilla" # => Wrong.config[:ice_cream] => "vanilla"
257
+
258
+ or any of these at runtime:
259
+
260
+ Wrong.config.ice_cream # => Wrong.config[:ice_cream] => true
261
+ Wrong.config.ice_cream = true # => Wrong.config[:ice_cream] => true
262
+ Wrong.config.ice_cream = "vanilla" # => Wrong.config[:ice_cream] => "vanilla"
263
+
264
+ ### Color ###
265
+
266
+ Apparently, no test framework is successful unless and until it supports console colors. So now we do. Call
267
+
268
+ Wrong.config.color
252
269
 
253
- Apparently, no test framework is successful unless and until it supports console colors. So now we do. Put
270
+ in your test helper or rakefile or wherever, or put
254
271
 
255
- Wrong.config[:color] = true
272
+ color
256
273
 
257
- in your test helper or rakefile or wherever and get ready to be **bedazzled**. If you need custom colors, let us know.
274
+ in your `.wrong` file and get ready to be **bedazzled**. If you need custom colors, let us know.
258
275
 
259
- ## Aliases ##
276
+ ### Aliases ###
260
277
 
261
- An end to the language wars! Name your "assert" and "deny" methods anything you want. Here are some suggestions:
278
+ An end to the language wars! Name your "assert" and "deny" methods anything you want. In your code, use `Wrong.config.alias_assert` and `Wrong.config.alias_deny`, and in your `.wrong` file, use Here are some suggestions:
262
279
 
263
- Wrong.config.alias_assert(:expect)
264
- Wrong.config.alias_assert(:should) # This looks nice with RSpec
265
- Wrong.config.alias_assert(:confirm)
266
- Wrong.config.alias_assert(:be)
280
+ alias_assert :expect
281
+ alias_assert :should # This looks nice in RSpec
282
+ alias_assert :confirm
283
+ alias_assert :be
267
284
 
268
- Wrong.config.alias_assert(:is)
269
- Wrong.config.alias_deny(:aint)
285
+ alias_assert :is
286
+ alias_deny :aint
270
287
 
271
- Wrong.config.alias_assert(:assure)
272
- Wrong.config.alias_deny(:refute)
288
+ alias_assert :assure
289
+ alias_deny :refute
273
290
 
274
- Wrong.config.alias_assert(:yep)
275
- Wrong.config.alias_deny(:nope)
291
+ alias_assert :yep
292
+ alias_deny :nope
276
293
 
277
- Wrong.config.alias_assert(:yay!)
278
- Wrong.config.alias_deny(:boo!)
294
+ alias_assert :yay!
295
+ alias_deny :boo!
279
296
 
280
297
  Just don't use "`aver`" since we took that one for an internal method in `Wrong::Assert`.
281
298
 
@@ -294,7 +311,8 @@ If you're in Ruby 1.8, you **really** shouldn't do it! But if you do, you can us
294
311
 
295
312
  ## Etc ##
296
313
 
297
- * Github projects: <http://github.com/alexch/wrong>, <http://github.com/sconover/wrong>
314
+ * Mailing list: <http://groups.google.com/group/wrong-rb>
315
+ * Github project: <http://github.com/sconover/wrong>
298
316
  * Tracker project: <http://www.pivotaltracker.com/projects/109993>
299
317
  * the [Wrong way translation table (from RSpec and Test::Unit)](https://spreadsheets.google.com/pub?key=0AouPn6oLrimWdE0tZDVOWnFGMzVPZy0tWHZwdnhFYkE&hl=en&output=html). (Ask <alexch@gmail.com> if you want editing privileges.)
300
318
  * the [Wrong slides](http://www.slideshare.net/alexchaffee/wrong-5069976) that Alex presented at Carbon Five and GoGaRuCo
data/lib/wrong/chunk.rb CHANGED
@@ -72,17 +72,19 @@ module Wrong
72
72
  end)
73
73
  end
74
74
 
75
- def read_source_file(file, dir = ".")
76
- File.read "#{dir}/#{file}"
75
+ def read_source_file(file)
76
+ Chunk.read_here_or_higher(file)
77
+ end
77
78
 
79
+ def self.read_here_or_higher(file, dir = ".")
80
+ File.read "#{dir}/#{file}"
78
81
  rescue Errno::ENOENT, Errno::EACCES => e
79
82
  # we may be in a chdir underneath where the file is, so move up one level and try again
80
83
  parent = "#{dir}/..".gsub(/^(\.\/)*/, '')
81
84
  if File.expand_path(dir) == File.expand_path(parent)
82
85
  raise Errno::ENOENT, "couldn't find #{file}"
83
86
  end
84
- read_source_file(file, parent)
85
-
87
+ read_here_or_higher(file, parent)
86
88
  end
87
89
 
88
90
  # Algorithm:
@@ -131,7 +133,7 @@ module Wrong
131
133
  self.claim.to_ruby
132
134
  rescue => e
133
135
  # note: this is untested; it's to recover from when we can't locate the code
134
- message = "Failed assertion at #{caller[depth + 2]} [couldn't retrieve source code due to #{e.inspect}]"
136
+ message = "Failed assertion at #{file}:#{line_number} [couldn't retrieve source code due to #{e.inspect}]"
135
137
  raise failure_class.new(message)
136
138
  end
137
139
 
@@ -196,10 +198,10 @@ module Wrong
196
198
  raises = raises.bold.color(:red)
197
199
  end
198
200
  formatted_exeption = if e.message and e.message != e.class.to_s
199
- indent(2, part, " ", raises, ": ", indent_all(3, e.message))
200
- else
201
- indent(2, part, " ", raises)
202
- end
201
+ indent(2, part, " ", raises, ": ", indent_all(3, e.message))
202
+ else
203
+ indent(2, part, " ", raises)
204
+ end
203
205
  details << formatted_exeption
204
206
  end
205
207
  end
data/lib/wrong/config.rb CHANGED
@@ -1,9 +1,38 @@
1
+ require "wrong/chunk"
2
+
1
3
  module Wrong
4
+ def self.load_config
5
+ settings = begin
6
+ Chunk.read_here_or_higher(".wrong")
7
+ rescue Errno::ENOENT => e
8
+ # couldn't find it
9
+ end
10
+ Config.new settings
11
+ end
12
+
2
13
  def self.config
3
- @config ||= Config.new
14
+ @config ||= load_config
15
+ end
16
+
17
+ def self.config=(new_config)
18
+ @config = load_config
4
19
  end
5
20
 
6
21
  class Config < Hash
22
+ def initialize(string = nil)
23
+ if string
24
+ instance_eval string.gsub(/^(.*=)/, "self.\\1")
25
+ end
26
+ end
27
+
28
+ def method_missing(name, value = true)
29
+ name = name.to_s
30
+ if name =~ /=$/
31
+ name.gsub!(/=$/, '')
32
+ end
33
+ self[name.to_sym] = value
34
+ end
35
+
7
36
  def alias_assert(method_name)
8
37
  Wrong::Assert.send(:alias_method, method_name, :assert)
9
38
  self.assert_method_names << method_name.to_sym unless self.assert_method_names.include?(method_name)
@@ -12,8 +12,8 @@ class Sexp < Array
12
12
 
13
13
  # visit every node in the tree, including the root, that is an Sexp
14
14
  # todo: test
15
- def each_subexp(&block)
16
- yield self
15
+ def each_subexp(include_root = true, &block)
16
+ yield self if include_root
17
17
  each do |child|
18
18
  if child.is_a?(Sexp)
19
19
  child.each_subexp(&block)
@@ -42,7 +42,7 @@ class Sexp < Array
42
42
  private
43
43
  def nested_assertions
44
44
  assertions = []
45
- self.each_of_type(:iter) { |sexp| assertions << sexp if sexp.assertion? }
45
+ self.each_subexp(false) { |sexp| assertions << sexp if sexp.assertion? }
46
46
  assertions
47
47
  end
48
48
 
data/lib/wrong/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Wrong
2
- VERSION = "0.4.0" unless defined?(Wrong::VERSION)
2
+ VERSION = "0.4.1" unless defined?(Wrong::VERSION)
3
3
  end
@@ -20,18 +20,18 @@ describe "advanced assert features" do
20
20
  end
21
21
  end
22
22
 
23
- xit "can parse a here doc defined inside the block" do
23
+ it "can parse a here doc defined inside the block" do
24
24
  # todo: test in Chunk too
25
- assert { "123\n456" == <<-TEXT
25
+ assert { "123\n456\n" == <<-TEXT
26
26
  123
27
27
  456
28
28
  TEXT
29
29
  }
30
30
  end
31
31
 
32
- xit "can parse a here doc defined outside the block" do
32
+ it "can parse a here doc defined outside the block" do
33
33
  # todo: test in Chunk too
34
- assert { "123\n456" == <<-TEXT }
34
+ assert { "123\n456\n" == <<-TEXT }
35
35
  123
36
36
  456
37
37
  TEXT
data/test/config_test.rb CHANGED
@@ -10,80 +10,120 @@ describe Wrong::Config do
10
10
  include Wrong
11
11
 
12
12
  before do
13
- Wrong.config.clear
13
+ @config = Wrong::Config.new
14
14
  end
15
15
 
16
- it "singleton" do
17
- c = Wrong.config
18
- assert { c.is_a?(Wrong::Config) }
19
- c2 = Wrong.config
20
- assert { c.object_id == c2.object_id }
16
+ it "has magic setters" do
17
+ config = Wrong::Config.new
18
+ config.foo = "bar"
19
+ assert { config[:foo] == "bar" }
20
+
21
+ config.baz
22
+ assert { config[:baz] }
23
+ end
24
+
25
+ it "reads from a string" do
26
+ config = Wrong::Config.new <<-SETTINGS
27
+ cold
28
+ flavor = "chocolate"
29
+ alias_assert :yum
30
+ SETTINGS
31
+ assert { config[:cold] }
32
+ assert { config[:flavor] == "chocolate" }
33
+ assert { config.assert_method_names.include? :yum }
21
34
  end
22
35
 
23
- # it "reads from a .wrong file"
36
+ describe "Wrong.config" do
37
+ it "is a singleton" do
38
+ c = Wrong.config
39
+ assert { c.is_a?(Wrong::Config) }
40
+ c2 = Wrong.config
41
+ assert { c.object_id == c2.object_id }
42
+ end
43
+
44
+ it "reads from a .wrong file in the current directory" do
45
+ wrong_settings = File.read(".wrong")
46
+ assert { wrong_settings != "" }
47
+ assert { Wrong.config[:test_setting] == "xyzzy" }
48
+ end
49
+
50
+ it "reads from a .wrong file in a parent directory" do
51
+ wrong_settings = File.read(".wrong")
52
+ Dir.chdir("test") do # move into a subdirectory
53
+ assert { Wrong.load_config[:test_setting] == "xyzzy" }
54
+ end
55
+ end
56
+
57
+ end
24
58
 
25
59
  it "getting an undeclared setting" do
26
- assert { Wrong.config[:foo].nil? }
60
+ assert { @config[:foo].nil? }
27
61
  end
28
62
 
29
63
  it "setting and getting" do
30
- Wrong.config[:foo] = "bar"
31
- assert { Wrong.config[:foo] == "bar" }
64
+ @config[:foo] = "bar"
65
+ assert { @config[:foo] == "bar" }
32
66
  end
33
67
 
34
- describe "adding aliases for assert" do
35
- before do
36
- Wrong.config.alias_assert(:is)
68
+ describe "adding aliases" do
69
+ after do
70
+ Wrong.config = Wrong::Config.new
37
71
  end
38
72
 
39
- it "succeeds" do
40
- is { 2 + 2 == 4 }
41
- end
73
+ describe "for assert" do
74
+ before do
75
+ Wrong.config.alias_assert(:is)
76
+ end
77
+
78
+ it "succeeds" do
79
+ is { 2 + 2 == 4 }
80
+ end
42
81
 
43
- it "fails" do
44
- e = rescuing {
45
- is("math is hard") { 2 + 2 == 5 }
46
- }
47
- expected = <<-FAIL
82
+ it "fails" do
83
+ e = rescuing {
84
+ is("math is hard") { 2 + 2 == 5 }
85
+ }
86
+ expected = <<-FAIL
48
87
  math is hard: Expected ((2 + 2) == 5), but 4 is not equal to 5
49
88
  (2 + 2) is 4
50
- FAIL
51
- assert { e.message == expected }
89
+ FAIL
90
+ assert { e.message == expected }
91
+ end
92
+
93
+ it "doesn't keep aliasing the same word" do
94
+ @config.alias_assert(:is)
95
+ @config.alias_assert(:is)
96
+ assert { @config.assert_method_names == [:assert, :is] }
97
+ end
52
98
  end
53
99
 
54
- it "doesn't keep aliasing the same word" do
55
- Wrong.config.alias_assert(:is)
56
- Wrong.config.alias_assert(:is)
57
- assert { Wrong.config.assert_method_names == [:assert, :is] }
58
- end
59
- end
60
-
61
- describe "adding aliases for deny" do
62
- before do
63
- Wrong.config.alias_deny(:aint)
64
- end
100
+ describe "for deny" do
101
+ before do
102
+ Wrong.config.alias_deny(:aint)
103
+ end
65
104
 
66
- it "succeeds" do
67
- aint { 2 + 2 == 5 }
68
- end
105
+ it "succeeds" do
106
+ aint { 2 + 2 == 5 }
107
+ end
69
108
 
70
- it "fails" do
71
- e = rescuing {
72
- aint("math is hard") { 2 + 2 == 4 }
73
- }
74
- expected = <<-FAIL
109
+ it "fails" do
110
+ e = rescuing {
111
+ aint("math is hard") { 2 + 2 == 4 }
112
+ }
113
+ expected = <<-FAIL
75
114
  math is hard: Didn't expect ((2 + 2) == 4), but 4 is equal to 4
76
115
  (2 + 2) is 4
77
- FAIL
78
- assert { e.message == expected }
79
- end
116
+ FAIL
117
+ assert { e.message == expected }
118
+ end
119
+
120
+ it "doesn't keep aliasing the same word" do
121
+ @config.alias_deny(:aint)
122
+ @config.alias_deny(:aint)
123
+ assert { @config.deny_method_names == [:deny, :aint] }
124
+ end
80
125
 
81
- it "doesn't keep aliasing the same word" do
82
- Wrong.config.alias_deny(:aint)
83
- Wrong.config.alias_deny(:aint)
84
- assert { Wrong.config.deny_method_names == [:deny, :aint] }
85
126
  end
86
127
 
87
128
  end
88
-
89
129
  end
data/test/test_helper.rb CHANGED
@@ -1,4 +1,8 @@
1
- puts "RUBY_VERSION=#{RUBY_VERSION}#{" (JRuby)" if Object.const_defined?(:JRuby)}"
1
+ puts(if Object.const_defined? :RUBY_DESCRIPTION
2
+ RUBY_DESCRIPTION
3
+ else
4
+ "ruby #{RUBY_VERSION} (#{RUBY_RELEASE_DATE} patchlevel #{RUBY_PATCHLEVEL}) [#{RUBY_PLATFORM}]"
5
+ end)
2
6
 
3
7
  dir = File.dirname(__FILE__)
4
8
  $LOAD_PATH.unshift "#{dir}/../lib"
@@ -37,7 +41,7 @@ end
37
41
 
38
42
  class MiniTest::Spec
39
43
  include MiniTest::Assertions
40
-
44
+
41
45
  class << self
42
46
  def xit(str)
43
47
  puts "x'd out test \"#{str}\""
metadata CHANGED
@@ -1,13 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wrong
3
3
  version: !ruby/object:Gem::Version
4
- hash: 15
5
4
  prerelease: false
6
5
  segments:
7
6
  - 0
8
7
  - 4
9
- - 0
10
- version: 0.4.0
8
+ - 1
9
+ version: 0.4.1
11
10
  platform: java
12
11
  authors:
13
12
  - Steve Conover
@@ -16,7 +15,7 @@ autorequire:
16
15
  bindir: bin
17
16
  cert_chain: []
18
17
 
19
- date: 2010-10-04 00:00:00 -07:00
18
+ date: 2010-10-06 00:00:00 -07:00
20
19
  default_executable:
21
20
  dependencies:
22
21
  - !ruby/object:Gem::Dependency
@@ -26,7 +25,6 @@ dependencies:
26
25
  requirements:
27
26
  - - ">="
28
27
  - !ruby/object:Gem::Version
29
- hash: 19
30
28
  segments:
31
29
  - 0
32
30
  - 2
@@ -42,7 +40,6 @@ dependencies:
42
40
  requirements:
43
41
  - - ~>
44
42
  - !ruby/object:Gem::Version
45
- hash: 7
46
43
  segments:
47
44
  - 2
48
45
  - 0
@@ -58,7 +55,6 @@ dependencies:
58
55
  requirements:
59
56
  - - ~>
60
57
  - !ruby/object:Gem::Version
61
- hash: 11
62
58
  segments:
63
59
  - 1
64
60
  - 2
@@ -73,7 +69,6 @@ dependencies:
73
69
  requirements:
74
70
  - - ~>
75
71
  - !ruby/object:Gem::Version
76
- hash: 7
77
72
  segments:
78
73
  - 3
79
74
  - 0
@@ -88,7 +83,6 @@ dependencies:
88
83
  requirements:
89
84
  - - ~>
90
85
  - !ruby/object:Gem::Version
91
- hash: 23
92
86
  segments:
93
87
  - 1
94
88
  - 1
@@ -169,7 +163,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
169
163
  requirements:
170
164
  - - ">="
171
165
  - !ruby/object:Gem::Version
172
- hash: 3
166
+ hash: 2619962454554443825
173
167
  segments:
174
168
  - 0
175
169
  version: "0"
@@ -178,7 +172,6 @@ required_rubygems_version: !ruby/object:Gem::Requirement
178
172
  requirements:
179
173
  - - ">="
180
174
  - !ruby/object:Gem::Version
181
- hash: 3
182
175
  segments:
183
176
  - 0
184
177
  version: "0"