Changeset 1168 for trunk/t/21_rdf.t
- Timestamp:
- 06/16/08 02:31:05 (6 months ago)
- Files:
-
- 1 modified
-
trunk/t/21_rdf.t (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/t/21_rdf.t
r1166 r1168 16 16 } 17 17 18 plan tests => 2 8;18 plan tests => 29; 19 19 20 20 Wiki::Toolkit::Setup::SQLite::setup( { dbname => "t/node.db" } ); … … 76 76 longitude => "-0.114436", 77 77 summary => "a nice pub", 78 node_image => "http://example.com/calthorpe.jpg", 78 79 ); 79 80 … … 82 83 like( $rdfxml, qr|<\?xml version="1.0"\?>|, "RDF is encoding-neutral" ); 83 84 84 like( $rdfxml, qr|<dc:title>Bloomsbury</dc:title>|, 85 like( $rdfxml, qr|<foaf:depiction rdf:resource="http://example.com/calthorpe.jpg" />|, "Node image"); 86 87 like( $rdfxml, qr|<wail:Neighborhood rdf:nodeID="Bloomsbury">|, 85 88 "finds the first locale" ); 86 like( $rdfxml, qr|< dc:title>St Pancras</dc:title>|,89 like( $rdfxml, qr|<wail:Neighborhood rdf:nodeID="St_Pancras">|, 87 90 "finds the second locale" ); 88 91 89 like( $rdfxml, qr|< phone>test phone number</phone>|,92 like( $rdfxml, qr|<contact:phone>test phone number</contact:phone>|, 90 93 "picks up phone number" ); 91 94 92 like( $rdfxml, qr|< chefmoz:Hours>test hours</chefmoz:Hours>|,95 like( $rdfxml, qr|<dc:available>test hours</dc:available>|, 93 96 "picks up opening hours text" ); 94 97 … … 111 114 "set the dc:source with the version-independent uri" ); 112 115 113 like( $rdfxml, qr|< country>United Kingdom</country>|, "country" ).114 like( $rdfxml, qr|< city>London</city>|, "city" ).115 like( $rdfxml, qr|< postalCode>WC1X 8JR</postalCode>|, "postcode" );116 like( $rdfxml, qr|<wail:City rdf:nodeID="city">\n\s+<wail:name>London</wail:name>|, "city" ). 117 like( $rdfxml, qr|<wail:locatedIn>\n\s+<wail:Country rdf:nodeID="country">\n\s+<wail:name>United Kingdom</wail:name>|, "country" ). 118 like( $rdfxml, qr|<wail:postalCode>WC1X 8JR</wail:postalCode>|, "postcode" ); 116 119 like( $rdfxml, qr|<geo:lat>51.524193</geo:lat>|, "latitude" ); 117 120 like( $rdfxml, qr|<geo:long>-0.114436</geo:long>|, "longitude" ); … … 170 173 $rdfxml = $rdf_writer->emit_rdfxml( node => "Nonesuch Stores" ); 171 174 172 like( $rdfxml, qr|<geo:SpatialThing rdf:ID="obj" dc:title="Nonesuch Stores">|,175 like( $rdfxml, qr|<geo:SpatialThing rdf:ID="obj">|, 173 176 "having opening hours marks node as geospatial" ); 174 177
