Measurement of the mechanical properties of thin films mechanically confined within contacts