Added update and render methods and implemented most of the tests