wrote a test case for 500 and made it pass