Check if audio is playing correctly using Selenium
You could check the audio element, after it should've started playing:
WebElement audio = driver.findElement(By.tagName("audio"));
String currentTime = audio.getAttribute("currentTime");
try {
assertTrue(Double.parseDouble(currentTime) > 0.0);
} catch(NumberFormatException ex) {
assertEquals(ex, null);
}
If it failed to load, or never started, then this test should fail.