Improvements on tests