TLDR: The Spanish fought a battle in 1812 knowing they were going to lose but had to for political reasons and tried to make the best of it with actually a pretty decent plan, but it went very badly for them. The 1811 Battle of Valencia probably best fits the description of a rigged battle in the most literal sense. The Spanish were holding defensive lines around Valencia, awaiting Marshal Suchet's inevitable attack. The Spanish were entrenched, but their army was marginally outnumbered and consisted of militia and demoralized line troops, though they did have the best divisions in the Spanish army at the time (Zayas' Spanish Guards and Lardizabal's division). Contrary to what many historians write, the Spanish generals were not dumb. They knew Suchet was going to attack their left flank where their defensive lines ended, and that they were pretty much cooked, to put it frankly. But because of the socio-political situation, they could not withdraw their army and abandon Valencia, or else their regency government would collapse as a result of a loss of popular support. The Regency government had many enemies in Cadiz and was already being undermined. Giving up the most important Spanish stronghold on the eastern coast without a fight would give its political opponents the fuel it needed to create a new government. The Spanish commander in Valencia, Joaquin Blake, was one of the three regents, so he had a personal stake in this affair. Blake and his generals decided to fight knowing that it was going to result in a defeat. They planned for a show battle where they could claim that they still put up a fight defending the city but were forced to retreat by superior French numbers to save face politically. What they planned for was a controlled retreat as the French inevitably overwhelmed their left flank. When the actual battle happened, the Spanish were caught off balance not by the fact that Suchet made a massive oblique attack on their left, but rather the timing of it. There was also a ton of horrendous miscommunication between the Spanish sector commanders that led to Suchet actually achieving some element of surprise even though the Spanish were very well aware of what he was doing. The critical part to the battle was not Suchet's main push against the Spanish left, but on the Spanish right, where his most aggressive divisional commander Habert, who was only supposed to mount a diversionary attack, went on a full assault that invertedly cut the last line of retreat available to the Spanish that had been Blake's fallback option even if the left wing collapsed.All of this is explained in greater detail in my book To Conquer and To Keep, vol II: https://www.amazon.com/Conquer-Keep-1809-1814-1811-1814-Revolution/dp/1804513962
