Sha256: e3e10993ea4ba7f80e76954cb9450437569886b93b8f6872f6730beadd4cb254
Contents?: true
Size: 848 Bytes
Versions: 7
Compression:
Stored size: 848 Bytes
Contents
require 'rdf' require 'rdf/spec' share_as :RDF_Value do before :each do raise '+@value+ must be defined in a before(:each) block' unless instance_variable_get('@value') raise '+@resource+ must be defined in a before(:each) block' unless instance_variable_get('@resource') end describe RDF::Value do it "should not be instantiable" do lambda { @value.call }.should raise_error(NoMethodError) end end describe RDF::Resource do it "should instantiate blank nodes" do resource = @resource.call('_:foobar') resource.class.should == RDF::Node resource.id.should == 'foobar' end it "should instantiate URIs" do resource = @resource.call('http://rdf.rubyforge.org/') resource.class.should == RDF::URI resource.to_s.should == 'http://rdf.rubyforge.org/' end end end
Version data entries
7 entries across 7 versions & 1 rubygems