Added unit test to verify #22458