This is the Vespa Testing reference for Vespa application system tests written in Java, as JUnit 5 unit test.
These tests verify the behaviour of a Vespa application by using its HTTP interfaces. To write tests without Java, see basic HTTP test reference.
See the testing guide for examples of how to run the tests.
The testing documentation defines three test scenarios, comprised of four test code categories. The system test framework in com.yahoo.vespa:tenant-cd-api uses Java annotations to declare what category a JUnit test class belongs to. To run tests with Maven belonging to a specific category, a JUnit 5 test tag must be specified:
|System test||@SystemTest||system||Independent, functional tests|
|Staging setup||@StagingSetup||staging-setup||Set state before upgrade|
|Staging test||@StagingTest||staging||Verify state after upgrade|
|Production test||@ProductionTest||production||Verify domain specific metrics|
For an example including system and staging tests, check out the sample application test suite.