More improvements and testing