fix tests etc..

some errors needed fixing