|
|
@ -83,6 +83,8 @@ fn sparql_w3c_query_evaluation_testsuite() { |
|
|
|
let manifest_10_urls = vec![ |
|
|
|
let manifest_10_urls = vec![ |
|
|
|
Url::parse("http://www.w3.org/2001/sw/DataAccess/tests/data-r2/algebra/manifest.ttl") |
|
|
|
Url::parse("http://www.w3.org/2001/sw/DataAccess/tests/data-r2/algebra/manifest.ttl") |
|
|
|
.unwrap(), |
|
|
|
.unwrap(), |
|
|
|
|
|
|
|
Url::parse("http://www.w3.org/2001/sw/DataAccess/tests/data-r2/ask/manifest.ttl") |
|
|
|
|
|
|
|
.unwrap(), |
|
|
|
Url::parse("http://www.w3.org/2001/sw/DataAccess/tests/data-r2/basic/manifest.ttl") |
|
|
|
Url::parse("http://www.w3.org/2001/sw/DataAccess/tests/data-r2/basic/manifest.ttl") |
|
|
|
.unwrap(), |
|
|
|
.unwrap(), |
|
|
|
Url::parse( |
|
|
|
Url::parse( |
|
|
@ -111,6 +113,8 @@ fn sparql_w3c_query_evaluation_testsuite() { |
|
|
|
.unwrap(), |
|
|
|
.unwrap(), |
|
|
|
Url::parse("http://www.w3.org/2001/sw/DataAccess/tests/data-r2/triple-match/manifest.ttl") |
|
|
|
Url::parse("http://www.w3.org/2001/sw/DataAccess/tests/data-r2/triple-match/manifest.ttl") |
|
|
|
.unwrap(), |
|
|
|
.unwrap(), |
|
|
|
|
|
|
|
Url::parse("http://www.w3.org/2001/sw/DataAccess/tests/data-r2/type-promotion/manifest.ttl") |
|
|
|
|
|
|
|
.unwrap(), |
|
|
|
]; |
|
|
|
]; |
|
|
|
let test_blacklist = vec![ |
|
|
|
let test_blacklist = vec![ |
|
|
|
//Multiple writing of the same xsd:integer. Our system does strong normalization.
|
|
|
|
//Multiple writing of the same xsd:integer. Our system does strong normalization.
|
|
|
@ -320,13 +324,30 @@ mod rs { |
|
|
|
pub static ref INDEX: NamedNode = |
|
|
|
pub static ref INDEX: NamedNode = |
|
|
|
NamedNode::from_str("http://www.w3.org/2001/sw/DataAccess/tests/result-set#index") |
|
|
|
NamedNode::from_str("http://www.w3.org/2001/sw/DataAccess/tests/result-set#index") |
|
|
|
.unwrap(); |
|
|
|
.unwrap(); |
|
|
|
|
|
|
|
pub static ref BOOLEAN: NamedNode = |
|
|
|
|
|
|
|
NamedNode::from_str("http://www.w3.org/2001/sw/DataAccess/tests/result-set#boolean") |
|
|
|
|
|
|
|
.unwrap(); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
fn to_graph(result: QueryResult) -> Result<MemoryGraph> { |
|
|
|
fn to_graph(result: QueryResult) -> Result<MemoryGraph> { |
|
|
|
match result { |
|
|
|
match result { |
|
|
|
QueryResult::Graph(graph) => Ok(graph), |
|
|
|
QueryResult::Graph(graph) => Ok(graph), |
|
|
|
QueryResult::Boolean(_) => unimplemented!(), |
|
|
|
QueryResult::Boolean(value) => { |
|
|
|
|
|
|
|
let graph = MemoryGraph::default(); |
|
|
|
|
|
|
|
let result_set = BlankNode::default(); |
|
|
|
|
|
|
|
graph.insert(&Triple::new( |
|
|
|
|
|
|
|
result_set.clone(), |
|
|
|
|
|
|
|
rdf::TYPE.clone(), |
|
|
|
|
|
|
|
rs::RESULT_SET.clone(), |
|
|
|
|
|
|
|
))?; |
|
|
|
|
|
|
|
graph.insert(&Triple::new( |
|
|
|
|
|
|
|
result_set.clone(), |
|
|
|
|
|
|
|
rs::BOOLEAN.clone(), |
|
|
|
|
|
|
|
Literal::from(value), |
|
|
|
|
|
|
|
))?; |
|
|
|
|
|
|
|
Ok(graph) |
|
|
|
|
|
|
|
} |
|
|
|
QueryResult::Bindings(bindings) => { |
|
|
|
QueryResult::Bindings(bindings) => { |
|
|
|
let graph = MemoryGraph::default(); |
|
|
|
let graph = MemoryGraph::default(); |
|
|
|
let result_set = BlankNode::default(); |
|
|
|
let result_set = BlankNode::default(); |
|
|
|