No, they can't.
Emphasis mine:
Swarm Subtype: A swarm is a collection of Fine, Diminutive, or Tiny creatures that acts as a single creature.
First, while a swarm may act as a single creature, it isn't one.
Second, you wouldn't Wild Shape into either a Small or Medium creature.
So, per the rules as written, you cannot Wild Shape into a swarm.
However, like you said, it can be a bit open to interpretation. You should consult your GM to see if they'd allow this. I probably would, depending on what kind of swarm.
Planar Shepherd
From Faiths of Eberron, is the only way I have found to Wild Shape into Outsiders. It limits you to Outsiders native to one specific plane. Certain planes have a good selection, notably Celestia (Celestials are very powerful for their HD total, and there are a lot of them in various splats).
If you just want to be a Druid who changes form into Outsiders, though
I.e. you aren't trying to use Divine Minion for infini-outsider, then there is a solution.
First of all, be a Half-Fiend with one level in the Savage Progression (or find some other Low-LA way to get the Outsider type, like being a Lesser Planetouched, or a Star Elf). Then, dip a level in Cleric, or qualify for the Contemplative (CDivine) prestige class. Choose the Alteration Domain(Dragonlance Campaign Setting). Take the Domain Spontaneity feat (CDivine). You may now exchange prepared Divine spells of 4th level or higher for Polymorph.
Congrats, you can be Outsiders.
Alternatively, wait until level 15 and be an Urban Druid. They get Polymorph Any Object.
A Psychoactive Skin of Proteus doesn't work as it explicitly bans outsiders.
Harder, and more cheesier alternatives include things like the Recaster (Races of Eberron), which lets you add a spell to your list of one level lower than the highest level of spell you know, and that spell can be from any class list. It requires 3rd level Arcane spells, and only advances arcane spellcasting though, so either Alternative Spell Source/Southern Magician or serious cheese would be required to get in.
The Spell Domain has the spell Greater Anyspell, but it specifies it can only be cast from the Domain Slot, not any other way - so it's essentially useless to you. Also only 5th level or worse spells, so only good if you're already an outsider.
Arcane Disciple could theoretically give you the Alteration Domain's Polymorph, but again it requires Arcane Magic and it changes those spells into Arcane Spells.
The Initiate feats might be able to help you, but they all specify 'add spells to your cleric list' so it's not exactly easy as a Druid to be having a cleric list. Rainbow Druidsnake? God knows.
Complete Champion has Domain Staffs, which are like a domain, in a staff. Cast spells from them like a runestaff, but wonkier.
The CO staple of a Drakehelm from the Explorer's Handbook (doesn't get more obscure than the Explorer's Handbook) straight up adds spells to your class list. It's a magic item. And completely ridiculous.
Complete Arcane has the draconic legacy feat which adds spells to your class list. Polymorph might be in there or arguable for one of the planar dragons or the other. You could get it through shenanigans. Probably. God, I don't know.
So yes, it's definitely possible. Easiest way is to just wait for Shapechange, the God-Spell, to come online at level 17. Or level 15 with Urban Druid and Polymorph Any Object. Before that you are going to have to pimp yourself to a god and go to Complete Divine, though, looks like.
Notably, Pathfinder has Planar Wild Shape, which basically shortcuts 99% of this effort by handing you the Outsider type on a silver planar-shaped platter.
They did away with polymorphing entirely though, in favour of set lists of abilities and enhancement bonuses to existing stats, so in the words of that famous guy, 'No dice!'.
Best Answer
Note the uses of the word Beasts in the description of what Wild Shape does.
Beasts is a defined term; from page 2 of the Dungeon Master Basic Rules:
You can Wild Shape into existing "Giant" animals
For Giant (x), if the creature meet the requirements of the Beast Shape table on page 66 and the Challenge Rating requirements on the same page, then the answer is yes, you can transform into a giant beast.
For example, a Giant Scorpion is described as
So it meets the Beast requirements, but its CR of 3 exceeds the maximum challenge rating of 1 for an 8th level druid. So you can't Wild Shape into a Giant Scorpion.
However, a Giant Poisonous Snake is CR ΒΌ, so you can Wild Shape into this creature if you seen it before and are at least 2nd level.
You can't Wild Shape into swarms
As for a swarm, the answer is no. This conclusion hinges on the wording of both Wild Shape and the Swarm creature.
Wild Shape (PHB page 66) opens with
The plain reading means the druid character can shape into a single beast.
The swarm descriptions are formatted like this:
For example a Swarm of Poisonous Snakes (DM's Basic Rules, page 46) is
So it clear that the "creature" is only treated as a single entity for the purpose of combat. It is really comprised of many creatures, whose action in concert gives the swarm its power.
My opinion is that they forgot to define or haven't finalized the definition of a swarm, which is why it doesn't appear in the list of standard creature types on page 2 of the 5e Dungeon Master's Basic Rules.