_clearText function was added
Some fixes in the tests