test: Add test for #7563. Closes #7563