Skip to content

Commit f18828b

Browse files
committed
Define the format URI to http://www.w3.org/ns/formats/LD_Patch.
1 parent 69ee66b commit f18828b

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

lib/ld/patch/format.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@ module LD::Patch
1111
#
1212
# @see http://www.w3.org/TR/ldpatch/
1313
class Format < RDF::Format
14-
content_type 'text/ldpatch', extension: :ldp
14+
content_type 'text/ldpatch',
15+
extension: :ldp,
16+
uri: 'http://www.w3.org/ns/formats/LD_Patch'
1517
content_encoding 'utf-8'
1618

1719
##

spec/format_spec.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@
2626
specify {expect(described_class.to_sym).to eq :ldpatch}
2727
end
2828

29+
describe "#to_uri" do
30+
specify {expect(described_class.to_uri).to eq RDF::URI('http://www.w3.org/ns/formats/LD_Patch')}
31+
end
32+
2933
describe ".cli_commands" do
3034
require 'rdf/cli'
3135
let(:nt) {File.expand_path("../test-files/1triple.nt", __FILE__)}

0 commit comments

Comments
 (0)