Added thumb tests, plus some small warning and bug fixes.