First of all, why did he attack you? I somehow doubt it happened for "no apparent reason", and if it was over drugs or something else illegal, I would drop the charges.

If you do decide to go to court, this guy claiming you are a pot smoker won't change anything unless you have been arrested and convicted for drugs in the past. A judge will not order drug testing for someone with no priors based on testimony of the guy who beat the shit out of him!