Added some tests for TreeDocument
Started to implement unit tests for DocumentManagerImpl