Branch: Tag:

2002-10-29

2002-10-29 03:25:07 by Martin Nilsson <mani@lysator.liu.se>

Updated for new RDF API

Rev: lib/modules/Standards.pmod/testsuite.in:1.3

1: - test_true([["$Id: testsuite.in,v 1.2 2002/09/14 13:11:34 nilsson Exp $"]]); + test_true([["$Id: testsuite.in,v 1.3 2002/10/29 03:25:07 nilsson Exp $"]]);      // - Standards.ISO639_2   test_equal(Standards.ISO639_2.get_language("swe"),"Swedish")
13:   test_equal_any([[    object r = Standards.RDF();    object x = r->Resource(); -  r->add_statement( r->Resource("http://www.example.org/index.html", 1), -  r->Resource("http://purl.org/dc/elements/1.1/creator", 1), +  r->add_statement( r->URIResource("http://www.example.org/index.html"), +  r->URIResource("http://purl.org/dc/elements/1.1/creator"),    x );    object y = r->Resource();    r->add_statement( x, -  r->Resource("http://www.example.org/terms/creation-date", 1), +  r->URIResource("http://www.example.org/terms/creation-date"),    y );    r->add_statement( y, -  r->Resource("http://pike.ida.liu.se/terms/ruppar", 1), -  r->Resource("August 16, 1999", 0) ); +  r->URIResource("http://pike.ida.liu.se/terms/ruppar"), +  r->LiteralResource("August 16, 1999") );    r->add_statement( x, -  r->Resource("http://www.example.org/terms/language", 1), -  r->Resource("English") ); +  r->URIResource("http://www.example.org/terms/language"), +  r->LiteralResource("English") );    return (multiset)(r->get_n_triples()/"\n");   ]], (< /* 5 elements */    "",