Implement is-over? function and write tests for it