Foamability and foam stability at high pressures and temperatures. I. Instrument validation