Added a test for #359.