adds ready event
adds some more tests