test for ref