aboutsummaryrefslogtreecommitdiff
path: root/test/uk/ac/ox/cs/pagoda/global_tests/TestPagodaLUBM.java
blob: bb586814bbcafc4707792ed1d6f9ee99b279c0d7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package uk.ac.ox.cs.pagoda.global_tests;

import org.testng.annotations.Test;
import uk.ac.ox.cs.pagoda.Pagoda;
import uk.ac.ox.cs.pagoda.util.TestUtil;

import java.io.IOException;
import java.nio.file.Paths;

public class TestPagodaLUBM {

	public void test(int number) throws IOException {
		String ontoDir = TestUtil.getConfig().getProperty("ontoDir");
		Pagoda pagoda = Pagoda.builder()
							  .ontology(Paths.get(ontoDir, "lubm/univ-bench.owl"))
							  .data(Paths.get(ontoDir, "lubm/data/lubm" + number + ".ttl"))
							  .query(Paths.get(ontoDir, "lubm/queries/test.sparql"))
							  .classify(true)
							  .hermit(true)
							  .build();
		CheckAnswersOverDataset.check(pagoda, Paths.get(ontoDir, "lubm/lubm" + number + ".json"));
	}

	@Test
	public void test_1() throws IOException {
		test(1);
	}

	public void justExecute_100() {
		int number = 100;
		String ontoDir = TestUtil.getConfig().getProperty("ontoDir");
		Pagoda pagoda = Pagoda.builder()
							  .ontology(Paths.get(ontoDir, "lubm/univ-bench.owl"))
							  .data(Paths.get(ontoDir, "lubm/data/lubm" + number + ".ttl"))
							  .query(Paths.get(ontoDir, "lubm/queries/test.sparql"))
							  .classify(true)
							  .hermit(true)
							  .build();
		pagoda.run();
	}

	public static void main(String... args) {
		new TestPagodaLUBM().justExecute_100();
	}
}