Add additional tests, fix logic to satisfy them.