add and improve tests