committee 0.4.9 → 0.4.10

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.
Files changed (2) hide show
  1. data/lib/committee/test/methods.rb +8 -1
  2. metadata +2 -2
@@ -3,7 +3,7 @@ module Committee::Test
3
3
  def assert_schema_conform
4
4
  assert_schema_content_type
5
5
 
6
- @schema ||= Committee::Schema.new(File.read(schema_path))
6
+ @schema ||= Committee::Schema.new(schema_contents)
7
7
  @router ||= Committee::Router.new(@schema)
8
8
 
9
9
  link_schema, type_schema =
@@ -30,6 +30,13 @@ module Committee::Test
30
30
  end
31
31
  end
32
32
 
33
+ # can be overridden alternatively to #schema_path in case the schema is
34
+ # easier to access as a string
35
+ # blob
36
+ def schema_contents
37
+ File.read(schema_path)
38
+ end
39
+
33
40
  def schema_path
34
41
  raise "Please override #schema_path."
35
42
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: committee
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.9
4
+ version: 0.4.10
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -151,5 +151,5 @@ rubyforge_project:
151
151
  rubygems_version: 1.8.24
152
152
  signing_key:
153
153
  specification_version: 3
154
- summary: A collection of middleware to support JSON Schema.
154
+ summary: A collection of Rack middleware to support JSON Schema.
155
155
  test_files: []