Add tests. Small tweaks.