- make
- golang
- docker: https://docs.docker.com/engine/install/
- docker compose: https://docs.docker.com/compose/install/
- act: https://github.com/nektos/act
- tmt: https://docs.fedoraproject.org/en-US/ci/tmt/#_install
The list of available workflows and the corresponding jobs can be listed with act -l:
➜ act -l
INFO[0000] Using docker host 'unix:///var/run/docker.sock', and daemon socket 'unix:///var/run/docker.sock'
Stage Job ID Job name Workflow name Workflow file Events
0 check-spelling check spelling Code scanning analysis.yml push,pull_request,schedule
0 commitlint check commitlint Code scanning analysis.yml push,pull_request,schedule
0 analysis_devskim check devskim Code scanning analysis.yml pull_request,schedule,push
0 test-rpms Test srpm and rpm builds Continuous integration ci.yml push,pull_request
0 test-onboarding Test FIDO device onboarding Continuous integration ci.yml push,pull_request
0 test-resale Test FIDO resale protocol Continuous integration ci.yml push,pull_request
0 test-fsim-wget Test FSIM wget Continuous integration ci.yml push,pull_request
0 test-fsim-upload Test FSIM upload Continuous integration ci.yml push,pull_request
0 test-fsim-download Test FSIM download Continuous integration ci.yml push,pull_request
0 test-container-fsim-fdo-wget Test FSIM fdo.wget Container Tests containers.yml push,pull_request
0 test-container-onboarding Test FIDO device onboarding Container Tests containers.yml push,pull_request
0 test-container-resale Test FIDO resale protocol Container Tests containers.yml pull_request,push
0 test-container-fsim-fdo-upload Test FSIM fdo.upload Container Tests containers.yml push,pull_request
0 test-container-fsim-fdo-download Test FSIM fdo.download Container Tests containers.yml push,pull_request When running the workflow jobs it's important to bind mount the ./test/workdir dir:
➜ act --container-options "-v ${PWD}/test/workdir:${PWD}/test/workdir" -j test-onboardingThe list of available tmt tests can be listed with tmt test ls:
➜ tmt test lsWhen running the tmt tests it's important to be verbose -vvv to see the actual test's output:
/test/fmf/tests/test-onboarding
➜ tmt -vvv run test --name /test/fmf/tests/test-onboardingIt's also possible to run the scripts directly without act or tmt.
Any script from ./test/{ci,container,fmf} directories can be executed from the shell:
- CI tests
➜ ./test/ci/test-onboarding.sh- Container tests
➜ ./test/container/test-onboarding.sh- TMT tests
➜ ./test/fmf/tests/test-onboarding.sh- Debugging
➜ sh -x ./test/ci/test-onboarding.sh
# or
➜ sh -x ./test/container/test-onboarding.sh
# or
➜ sh -x ./test/fmf/tests/test-onboarding.shRPM tests deploy the FDO servers using RPM packages. These tests support multiple installation sources controlled by environment variables.
The RPM tests support the following installation sources:
- distro-repos - Install from standard distribution repositories
- fedora-iot-copr - Install from the fedora-iot COPR repository
- compose - Install from a specific compose URL
Control which installation source to use with these environment variables:
INSTALLATION_SOURCE- Sets the installation source for both client and serverCLIENT_INSTALLATION_SOURCE- Override installation source for the client onlySERVER_INSTALLATION_SOURCE- Override installation source for the server only
➜ INSTALLATION_SOURCE=distro-repos ./test/rpm/test-onboarding.sh➜ INSTALLATION_SOURCE=fedora-iot-copr ./test/rpm/test-onboarding.shFor Fedora and CentOS Stream, the compose URL is automatically detected based on the OS version:
➜ INSTALLATION_SOURCE=compose ./test/rpm/test-onboarding.shFor RHEL, you must specify the compose base URL:
➜ INSTALLATION_SOURCE=compose \
COMPOSE_BASE_URL="http://download.host/.../latest-RHEL-Compose/compose/" \
./test/rpm/test-onboarding.shYou can override the compose URL and streams for any distribution:
# Custom compose URL
➜ INSTALLATION_SOURCE=compose \
COMPOSE_BASE_URL="http://custom.host/compose/path/" \
./test/rpm/test-onboarding.sh
# Custom streams (default: "Everything" for Fedora, "BaseOS AppStream" for CentOS/RHEL)
➜ INSTALLATION_SOURCE=compose \
COMPOSE_STREAMS="BaseOS AppStream" \
./test/rpm/test-onboarding.sh
# Both custom URL and streams
➜ INSTALLATION_SOURCE=compose \
COMPOSE_BASE_URL="http://custom.host/compose/path/" \
COMPOSE_STREAMS="BaseOS AppStream CRB" \
./test/rpm/test-onboarding.shYou can run any RPM test from the test/rpm/ directory:
# List available RPM tests
➜ ls test/rpm/test-*.sh
# Run specific tests
➜ INSTALLATION_SOURCE=compose ./test/rpm/test-device-ca-api.sh
➜ INSTALLATION_SOURCE=compose ./test/rpm/test-fsim-wget.sh
➜ INSTALLATION_SOURCE=compose ./test/rpm/test-resale.shWhen INSTALLATION_SOURCE is not set:
- If running in a development environment with spec files present, RPMs are built locally from the current git commit
- Otherwise, packages are installed from the fedora-iot COPR repository