Add Test for Payment Tool, fix minor issues