version with tests