1) Russia-Iranian relation must last. China relies on global supply chains for its sweatshop exports and Saudi oil. The Chinese bend nearly every time America makes a demand. Russia on the other hand is one of the few self-efficient nations in the world, and remains the world's #2 military power.
Most Chinese weaponry, even to this day, still use imported, stolen or copied core Russian technology. Unlike China, Russia does not bend.
2) Iran is no where near a science or technology power. The country does not even have the capacity to refine its own crude into gasoline. The last time China exported refiners to Iran, the US demanded for that to stop, and stop they did. The Chinese will land a man on the moon, launch ICBMs which can reach anywhere in the world, #2 in Olympic medals, produce 5th generation jets -- achievements that Iran can only dream of.
3) The Chinese will also surpass Iran in per capita GDP in 2 years. The average Chinese will be significantly wealthier than the average Iranian. China surpasses Iran in every index from science to technology, education to infrastructure, collective to individual. The only thing Iran can offer is oil, most of which must be shipped by containers through the Indian Ocean, hardly a safe energy source for China.
4) The ideal Chinese ally is one which can bolster its claims to the South China seabed, -- its only possible major source of secured energy resource. Iran is not remotely near the region geographically, nor does it have the naval presence. As such it will forever remain a card which the Chinese will discard when the Americans are politically committed enough to cut a deal with the Communist state.