The "militants" were holding on stubbornly to their position in the scabrous desert outside Baghdad, blocking the Iraqi troops' advance when an infantry unit sprung out of the right flank, forcing the enemy into a hasty retreat.
At first glance, it looked real, but the scenario playing out this week was not an operation against the ISIS group but a military exercise. The "militants" were Iraqi soldiers, and the guns were firing blanks.
The exercise was the final day in the drill of the 2,000-strong Iraqi brigade, the latest group to receive combat training from Australian, New Zealand, and Singaporean coalition forces at the sprawling Taji military base, north of Baghdad. It's known as Task Group Taji 8 and the maneuver displayed some of the tactics drilled into the brigade during the eight-week course.
Since before last month's final territorial defeat the ISIS group in Syria, when the militants lost the last pocket of their so-called caliphate to coalition-backed forces, the U.S.-led international coalition has been training Iraqi forces to secure the country against lingering threats posed by cells of ISIS operating in the countryside.
"While the physical caliphate of ISIS has been defeated, ISIS is still in insurgency mode at this stage," said Col. Jason Groat, commander the Task Group Taji 8 force drilling the Iraqi army.
The ISIS at its height in the summer of 2014 , commanded a pseudo-state that stretched across a third of both Syria and Iraq and included Mosul, Iraq's third-largest city. Today, the group is a shadow of what it once was — ISIS no longer holds any urban areas on congruous stretch of territory but still mounts kidnappings, ambushes and assassinations in rural Iraq.
"Our job is to keep the Iraqi security forces trained up to speed and make sure they can defeat ISIS whatever phase of the war they happen to be in," Groat added.
Training the Iraqi army is a core objective of the coalition. Poorly trained and equipped, underfunded, and corrupted in the decade after the 2003 U.S.-led invasion of Iraq, the army disintegrated in the face of ISIS sweeping advance.
It was then that the Iraqi parliament voted to invite international forces back into the country, to turn the tide in the war against ISIS.
But with ISIS defeated, the talk in Baghdad has again turned to whether foreign forces should stay. There are currently about 5,200 U.S. troops supporting Iraqi operations in mop up operations in the countryside.
If they are ordered out, the training by the 340-strong Task Group Taji 8 could be a collateral casualty. The group has trained 44,000 Iraqi soldiers since 2015.
Col. Groat says his men will continue training Iraqi forces as long as the Iraqi government wants them to.
"We'll be here until the job is done," he said.