tests working and minor updates