Adds more unit tests and refactors-out integer-specific logic from the generic INumber protocol