Fixed some tests and added others.
Merge remote-tracking branch 'origin/master'