The decision of when to pay the mechanic should be an agreement between the two of you. But it'd be advisable to pay the mechanic in bits. Half(or lesser) the amount before he does the job (just in case he needs to purchase some items for the work to be done) and the complete amount when he/she does the job.
I usually pay my mechanic when he is done with the job because I trust him as much as he trusts me and we've been working together for quite a while now.
Cheers