Indeed, but this is where is becomes clear that the AI doesn't fully get 1upt.
I've had plenty of games where I've defended a city purely though it's own defenses and by having a collection of ranged units. The AI just marches right into their waiting jaws over and over and over again.
While the armies get larger, the tactics don't change so it's just rinse and repeat.
While I'm not complaining really, it just gets tiresome having to keep up the same pointless defensive move for 100 turns +
Counter invasion is, as you said, the only solution. It would just be nice if the AI figured out that it was approaching that city from entirely the wrong way.
This has been the case with AI for all Civ game, it's one sized fits all strategy, only the AI gets to play with more units the harder you go.
On higher difficulty, the AI is much harder to attack as well, becaue they can easily have 3-4 bombard units defending and they rushbuy/build these almost every turn.
The Civ5 AI also keep reserves. You can beat back an attack, mass your forces and move against the AI and you'll see a wall of troops rush in from behind the fog of war. It takes a while to completely break the AI militarily, and you can't do it turtling in your territory, because their reserves will never come into play. You have to invade and wipe out their reserves.