Add unit tests for parts of CtfEditor.