Post-Newtonian metric for a general class of scalar-tensor gravitational theories and observational consequences