test: Add two tests for issue #6272.