rdf-spec 3.1.1 → 3.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 359d4ed64e3fae2fad591b97229517ecf8e789b8034d02aa3f5f3c321713eeb2
4
- data.tar.gz: 615e856800be204c17f5fff44d6c7f2ede8f103cb86f058b71b11918c2402f75
3
+ metadata.gz: 7fcc3f1dc608559386697ccc24fdedae95f1ddc32ec63a7d597ddb58f81b6e09
4
+ data.tar.gz: e1c9dc6188a51add0494b58e01bfdcc35e0a5c3d5b32244e21126144cf1833b9
5
5
  SHA512:
6
- metadata.gz: bddc0c1b5819a5ae83dcb4a465544ac3065d3e4d0a9bae26255eab469f983c9395e74104a3d02e69fd7d11daabca976d73aa3821780dc2559a86d60d3b588b16
7
- data.tar.gz: 5bf145f2037a531f81bf363658261b7cca64b5f79b200383eb23e7228a48d0339257526cca0ca166b4dde6379f94a45e20e109b446cd30dae870fa2557431d16
6
+ metadata.gz: 63315553b33a31e334d534e2d75db534e542e486764d288c06575f0291590be978b6499f957780c015cba55805dfea0f99a6777e1e9e986ac9d29e4a84608d8b
7
+ data.tar.gz: ebbe887a96cae5f1d174f5d143528ad1e3e881f191c0ff9f389302bd010d7854502f74f91cc0d6d8aa326e7fea82f0f0df937794eadc3dc12a1c6e79efd42556
data/README.md CHANGED
@@ -3,11 +3,10 @@
3
3
  This is an [RDF.rb][] extension that provides RDF-specific [RSpec][] matchers
4
4
  and shared examples for Ruby projects that use RDF.rb and RSpec.
5
5
 
6
- * <https://github.com/ruby-rdf/rdf-spec>
7
-
8
6
  [![Gem Version](https://badge.fury.io/rb/rdf-spec.png)](https://badge.fury.io/rb/rdf-spec)
9
- [![Build Status](https://travis-ci.org/ruby-rdf/rdf-spec.png?branch=master)](https://travis-ci.org/ruby-rdf/rdf-spec)
10
- [![Coverage Status](https://coveralls.io/repos/ruby-rdf/rdf-spec/badge.svg)](https://coveralls.io/r/ruby-rdf/rdf-spec)
7
+ [![Build Status](https://github.com/ruby-rdf/rdf-spec/workflows/CI/badge.svg?branch=develop)](https://github.com/ruby-rdf/rdf-spec/actions?query=workflow%3ACI)
8
+ [![Coverage Status](https://coveralls.io/repos/ruby-rdf/rdf-spec/badge.svg)](https://coveralls.io/github/ruby-rdf/rdf-spec)
9
+ [![Gitter chat](https://badges.gitter.im/ruby-rdf/rdf.png)](https://gitter.im/ruby-rdf/rdf)
11
10
 
12
11
  ## Documentation
13
12
 
@@ -76,7 +75,9 @@ follows:
76
75
  enough, be assured we will eventually add you in there.
77
76
  * Do note that in order for us to merge any non-trivial changes (as a rule
78
77
  of thumb, additions larger than about 15 lines of code), we need an
79
- explicit [public domain dedication][PDD] on record from you.
78
+ explicit [public domain dedication][PDD] on record from you,
79
+ which you will be asked to agree to on the first commit to a repo within the organization.
80
+ Note that the agreement applies to all repos in the [Ruby RDF](https://github.com/ruby-rdf/) organization.
80
81
 
81
82
  License
82
83
  -------
@@ -87,4 +88,4 @@ see <https://unlicense.org/> or the accompanying {file:UNLICENSE} file.
87
88
  [RDF.rb]: https://rubygems.org/gems/rdf
88
89
  [RSpec]: https://rspec.info/
89
90
  [RubySpec]: https://rubyspec.org/wiki/rubyspec/Style_Guide
90
- [PDD]: https://lists.w3.org/Archives/Public/public-rdf-ruby/2010May/0013.html
91
+ [PDD]: https://unlicense.org/#unlicensing-contributions
data/VERSION CHANGED
@@ -1 +1 @@
1
- 3.1.1
1
+ 3.1.2
@@ -87,7 +87,7 @@ module RDF
87
87
  end
88
88
  end
89
89
  logger.level = Logger::DEBUG
90
- logger.formatter = lambda {|severity, datetime, progname, msg| "#{severity} #{msg}\n"}
90
+ logger.formatter = lambda {|severity, datetime, progname, msg| "%5s %s\n" % [severity, msg]}
91
91
  logger
92
92
  end
93
93
  end # Spec
@@ -266,16 +266,16 @@ module RDF; module Spec
266
266
  end
267
267
  end
268
268
 
269
- Info = Struct.new(:id, :logger, :action, :result, :format)
269
+ Info = Struct.new(:id, :logger, :action, :result, :format, :base, :prefixes)
270
270
 
271
271
  RSpec::Matchers.define :be_equivalent_graph do |expected, info|
272
272
  match do |actual|
273
273
  @info = if (info.id rescue false)
274
274
  info
275
275
  elsif info.is_a?(Logger)
276
- Info.new("", info)
276
+ Info.new(logger: info)
277
277
  elsif info.is_a?(Hash)
278
- Info.new(info[:id], info[:logger], info[:action], info[:result], info[:format])
278
+ Info.new(info[:id], info[:logger], info[:action], info[:result], info[:format], info[:base], info[:prefixes])
279
279
  else
280
280
  Info.new(info)
281
281
  end
@@ -290,6 +290,13 @@ module RDF; module Spec
290
290
  end
291
291
 
292
292
  failure_message do |actual|
293
+ dump_opts = {
294
+ standard_prefixes: true,
295
+ literal_shorthand: false,
296
+ validate: false,
297
+ base_uri: @info.base,
298
+ prefixes: @info.prefixes
299
+ }
293
300
  info = @info.respond_to?(:information) ? @info.information : @info.inspect
294
301
  if @expected.is_a?(RDF::Enumerable) && @actual.size != @expected.size
295
302
  "Graph entry counts differ:\nexpected: #{@expected.size}\nactual: #{@actual.size}\n"
@@ -297,12 +304,19 @@ module RDF; module Spec
297
304
  "Graphs differ\n"
298
305
  end +
299
306
  "\n#{info + "\n" unless info.empty?}" +
300
- "Expected:\n#{@expected.dump(@info.format, standard_prefixes: true, literal_shorthand: false, validate: false) rescue @expected.inspect}" +
301
- "Results:\n#{@actual.dump(@info.format, standard_prefixes: true, literal_shorthand: false, validate: false) rescue @actual.inspect}" +
307
+ "Expected:\n#{@expected.dump(@info.format, **dump_opts) rescue @expected.inspect}" +
308
+ "Results:\n#{@actual.dump(@info.format, **dump_opts) rescue @actual.inspect}" +
302
309
  "\nDebug:\n#{@info.logger}"
303
310
  end
304
311
 
305
312
  failure_message_when_negated do |actual|
313
+ dump_opts = {
314
+ standard_prefixes: true,
315
+ literal_shorthand: false,
316
+ validate: false,
317
+ base: @info.base,
318
+ prefixes: @info.prefixes
319
+ }
306
320
  format = case
307
321
  when RDF.const_defined?(:TriG) then :trig
308
322
  when RDF.const_defined?(:Turtle) then :ttl
@@ -311,7 +325,7 @@ module RDF; module Spec
311
325
  info = @info.respond_to?(:information) ? @info.information : @info.inspect
312
326
  "Graphs identical\n" +
313
327
  "\n#{info + "\n" unless info.empty?}" +
314
- "Results:\n#{actual.dump(@info.format, standard_prefixes: true, literal_shorthand: false, validate: false) rescue @actual.inspect}" +
328
+ "Results:\n#{actual.dump(@info.format, **dump_opts) rescue @actual.inspect}" +
315
329
  "\nDebug:\n#{@info.logger}"
316
330
  end
317
331
 
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rdf-spec
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.1
4
+ version: 3.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arto Bendiken
8
8
  - Ben Lavender
9
9
  - Gregg Kellogg
10
- autorequire:
10
+ autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2020-05-30 00:00:00.000000000 Z
13
+ date: 2020-12-25 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rdf
@@ -19,6 +19,9 @@ dependencies:
19
19
  - - "~>"
20
20
  - !ruby/object:Gem::Version
21
21
  version: '3.1'
22
+ - - ">="
23
+ - !ruby/object:Gem::Version
24
+ version: 3.1.8
22
25
  type: :runtime
23
26
  prerelease: false
24
27
  version_requirements: !ruby/object:Gem::Requirement
@@ -26,6 +29,9 @@ dependencies:
26
29
  - - "~>"
27
30
  - !ruby/object:Gem::Version
28
31
  version: '3.1'
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: 3.1.8
29
35
  - !ruby/object:Gem::Dependency
30
36
  name: awesome_print
31
37
  requirement: !ruby/object:Gem::Requirement
@@ -82,6 +88,20 @@ dependencies:
82
88
  - - "~>"
83
89
  - !ruby/object:Gem::Version
84
90
  version: '1.3'
91
+ - !ruby/object:Gem::Dependency
92
+ name: rexml
93
+ requirement: !ruby/object:Gem::Requirement
94
+ requirements:
95
+ - - "~>"
96
+ - !ruby/object:Gem::Version
97
+ version: '3.2'
98
+ type: :runtime
99
+ prerelease: false
100
+ version_requirements: !ruby/object:Gem::Requirement
101
+ requirements:
102
+ - - "~>"
103
+ - !ruby/object:Gem::Version
104
+ version: '3.2'
85
105
  - !ruby/object:Gem::Dependency
86
106
  name: webmock
87
107
  requirement: !ruby/object:Gem::Requirement
@@ -102,14 +122,14 @@ dependencies:
102
122
  requirements:
103
123
  - - "~>"
104
124
  - !ruby/object:Gem::Version
105
- version: 0.9.20
125
+ version: '0.9'
106
126
  type: :development
107
127
  prerelease: false
108
128
  version_requirements: !ruby/object:Gem::Requirement
109
129
  requirements:
110
130
  - - "~>"
111
131
  - !ruby/object:Gem::Version
112
- version: 0.9.20
132
+ version: '0.9'
113
133
  description: RDF.rb extension that provides RSpec matchers and shared examples for
114
134
  RDF objects.
115
135
  email: public-rdf-ruby@w3.org
@@ -174,7 +194,7 @@ homepage: https://github.com/ruby-rdf/rdf-spec/
174
194
  licenses:
175
195
  - Unlicense
176
196
  metadata: {}
177
- post_install_message:
197
+ post_install_message:
178
198
  rdoc_options: []
179
199
  require_paths:
180
200
  - lib
@@ -189,8 +209,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
189
209
  - !ruby/object:Gem::Version
190
210
  version: '0'
191
211
  requirements: []
192
- rubygems_version: 3.1.3
193
- signing_key:
212
+ rubygems_version: 3.2.3
213
+ signing_key:
194
214
  specification_version: 4
195
215
  summary: RSpec extensions for RDF.rb.
196
216
  test_files: []