On 5 February 249, Cao Shuang and his brothers accompanied the emperor, Cao Fang, on a visit to the Gaoping Mausoleum () to pay their respects to the late emperor, Cao Rui. On that day, Sima Yi seized the opportunity to stage a "coup d'état" against his co-regent. He went to Yongning Palace to meet Empress Dowager Guo to request the memorialisation of a decree ordering the removal of Cao Shuang and his brothers from power. Thereafter, all the city gates were closed while Sima Shi's previously-arranged 3,000 forces which had gathered at the Sima Gate () under his command were led to occupy the palace gates. Sima Yi later even commented: "This son really worked well." Soon, the troops were lined up along the palace grounds, passing through Cao Shuang's camp. Cao Shuang's Controller of Camp, Yan Shi (), was on the upper floor, drawing his crossbow, intending to shoot the passing Sima Yi. His colleague Sun Qian () stopped him and said: "We wouldn't know what will happen." Three times he focused, three times he stopped, every time pulling back his elbow, but not getting to shoot.