should write a test for that