Survival
Survival is a special mode that has you on the defensive and it unlocks at Command Center level 4. Survival Mode, as previously mentioned, is a defensive mode that will unleash various units, wave after wave on your base.
The goal is to survive for as long as possible so make sure that your base's setup is well and good. You cannot know for sure what types of units show up and where they will be spawned, but if the attacking units pass through an area you want them to, you can see how well your defenses work in that area.
Since Survival Mode's goal is to survive as many waves as possible, it doesn't expect you to do it in one sitting. There is a checkpoint system in place here in which it records the Base Integrity of your base after each wave. The checkpoint is placed at the wave that you survived with 75% Base Integrity. You also receive 3 maximum tries at survival with more free tries given after a few hours.