Add new test from Jean-Damien Durand
Add regression test of bug found by Jean-Damien Durand