Add a test for the bug fixed by the previous commit.