add test for invalid type