joomla/joomla-platform — pull request #1178 by florianv (2012-05-01 20:08:34+00:00)
Title: JEditor unit tests

Hello,

I made unit tests for JEditor which cover everything besides _loadEditor() which cannot be covered.

JEditor doesn't pass two tests ending with a fatal error.

testGetContentWithoutData()
testSetContentWithoutData()

If for some reasons loadEditor fails : for example the none editor plugin doesn't exist, getContent() and setContent() will call $this->_editor->update($args); on a non-object, because $this->_editor is still null.

The case is covered in the save() and display() functions but not in setContent() and getContent().