Fixing tests and docs