Testing in the OpenTelemetry Demo project involves running unit tests, integration tests, and end-to-end tests. The Makefile in the project’s root directory provides functions to run these tests.
Unit tests
Unit tests in the OpenTelemetry Demo project are written using various testing frameworks depending on the programming language used. For example, in the api
directory, Go’s built-in testing framework is used, while in the instrumentation/java
directory, JUnit is used. To run unit tests for all languages, use the test
target in the Makefile:
make test
Integration tests
Integration tests in the OpenTelemetry Demo project involve testing the interaction between components. These tests are also run using the test
target in the Makefile:
make test
End-to-end tests
End-to-end tests in the OpenTelemetry Demo project involve testing the entire system from end to end. These tests are also run using the test
target in the Makefile:
make test