update tests and code from work