Re #9199. Added a unit test