added new tests and fixed existing tests