log document and some tests added