test for open/close