New tests (+ fixes for bugs revealed)