Fix trivial error, add more tests