tests for #353
fix #353
tests for #354