Fixes to tests generator, documentation.