ran tests and minor tweaks