Use the dependencies BOM to ensure versions used in the `MavenBuild` test class are always aligned. Closes gh-23936