Added check datatypes against those in QBO docs. Tidied and fixed tests.