Background
- Linked Data Platform 1.0 (W3C Candidate Recommendation 19 June 2014)
- Linked Data Platform Use Cases and Requirements (W3C Working Group Note 13 March 2014)
- Linked Data Platform 1.0 Primer (W3C First Public Working Draft 26 June 2014)
- LDP Best Practices and Guidelines (W3C Editor's Draft 17 April 2014)
- Linked Data Platform 1.0 Test Cases (W3C Working Group Note 25 August 2014)
Status
This Test Suite is still work-in-progress (see conformance reports and coverage reports), but you could start to use it to check your implementation and send some early feedback to the working group.
The list of test cases, along with their status (WG approved, manual, client-only) is available in a generated report.
Usage
Standalone
You can run the test suite against an arbitrary server:
$ mvn package
$ java -jar target/ldp-testsuite-0.1.1-shaded.jar \
--server http://localhost --basic
--basic
, --direct
, or --indirect
for the type of container
you want to test;
--help
for getting some more help.
You can also run the test suite against the Paging Specification Requirements by using the following command (paging tests are still work-in-progress):
$ java -classpath target/ldp-testsuite-1.0.0-SNAPSHOT-shaded.jar \
org.w3.ldp.paging.testsuite.tests.RunPagingTest
Maven
If you are using Maven for building your project, you can use the test suite, available from Maven Central, as dependency for your tests:
<dependency>
<groupId>org.w3</groupId>
<artifactId>ldp-testsuite</artifactId>
<version>0.1.1</version>
<scope>test</scope>
</dependency>
And then you can programmatically execute the test suite with a code like:
LdpTestSuite testSuite = new LdpTestSuite("http://localhost");
testSuite.run();
System.out.println(testSuite.getStatus());
For complete programmatic usage example, you can check how Apache Marmotta integrates the LDP Test Suite in the regular build. For further details and advance usage, please check the javadoc.
Eclipse
If you are running from Eclipse IDE, you can leverage a TestNG plugin. There is a sample testng.xml with all the parameters. Simply update testng.xml and select it, right click and chose "Run As -> TestNG Test suite".
Reporting
For reporting the status of a concrete implementation, please use a command like:
$ java -jar target/ldp-testsuite-0.1.1-shaded.jar \
--server http://localhost --basic --non-rdf --earl \
--software "Your Software" --shortname "Yours" --language "Java" \
--homepage http://ldp.example.org \
--assertor http://ldp.example.org \
--developer "Your Name"
Please, submit the generated reports, (both ldp-testsuite-execution-report-earl.ttl
and
ldp-testsuite-execution-report.html
located at the report
directory, to the working
group (public-ldp-comments@w3.org)
to be included to the official LDP Implementation Conformance Report.
Contributors
On behalf of the W3C LDP Working Group:
Contributing Test Cases
The LDP test suite represents a developed set of test cases, as automated as possible using TestNG and REST-assured. These test cases are contributed via typical individuals who update the source code and send in a pull request. The maintainers of the repo, review the contribution to ensure the quality. New test cases should be annotated with the appropriate annotation:
@SpecTest(approval = STATUS.WG_PENDING)
Once there are at least 2 implementations passing this new test, the status will be changed to STATUS.WG_APPROVED
.
Licenses
The Test Suite software is avaible under the terms of the W3C Software Notice and License. To contribute to the Test Suite software, you have to sign the Contributor License Agreement.
The Test Suite data is available under both W3C Test Suite License and W3C 3-clause BSD License. To contribute to the Test Suite data, see the policies and contribution forms.