writing tests. fixing bugs.