Audio Testing of VirtualBox

Overview / Goal

The goal is to create a flexible testing framework to test the VirtualBox audio stack.

It should be runnable with an easy-to-use setup so that also regular users can perform tests on request, without having to install or set up additional dependencies.

That framework must be runnable on all host/guest combinations together with all audio drivers ("backends") and device emulations being offered. This makes it a rather big testing matrix which therefore has to be processed in an automated fashion.

Additionally it should be flexible enough to add more (custom) tests later on.

Operation

The framework consists of several components which try to make use as much of the existing audio stack code as possible. This allows the following operation modes:

Standalone
Playing back / recording audio data (test tones / .WAV files) in a standalone scenario, i.e. no VirtualBox / VMs required). This mode is using VirtualBox' audio (mixing) stack and available backend drivers without the need of VirtualBox being installed.
Manual
Performing single / multiple tests manually on a local machine. Requires a running and set up test VM.
Automated
Performs single / multiple tests via the Validation Kit audio test driver and can be triggered via the Validation Kit Test Manager.
(Re-)validation of previously ran tests
This takes two test sets and runs the validation / analysis on them.
Self testing mode
Performs standalone self tests to verify / debug the involved components.

Components and Terminology

The following components are in charge for performing the audio tests (depends on the operation mode, see above):

The above components are also included in VirtualBox release builds and can be optionally enabled (disabled by default).

[1]src/VBox/ValidationKit/tests/audio/tdAudioTest.py

Setup instructions

Performing a manual test

Advanced: Performing manual verification

VBoxAudioTest can manually be used with the "verify" sub command in order to (re-)verify previously generated test sets. It then will return different exit codes based on the verification result.

Advanced: Performing an automated test

Internals: Workflow for a single test

When a single test is being executed on a running VM, the following (simplified) workflow applies:

Current status / limitations

Troubleshooting

Status:$Id: VBoxAudioValidationKitReadMe.html 106065 2024-09-16 21:42:41Z vboxsync $
Copyright:Copyright (C) 2021-2024 Oracle Corporation.