Improved unit tests for #2608