Add test for #clear