The mechanical integrity of the casing and cement is tested to ensure proper installation at multiple stages of the drilling and completion process, using techniques such as pressure testing, and wire line and bond logging.