Amount validity and compatibility checking + AmountTest