Deadly Graduation

A classic for evil training programs, especially for assassins. Relatively good and innocent characters are trained in combat skills in a harsh and often deadly program. Often they are made to train in pairs for years building reliance on their partner. Now it is time for their final test. They must battle their best friend to the death!

A variation on this is the character's partner goes missing shortly before this mysterious exam only to be found tied up in the exam room with the test being to shoot them in cold blood. This can often end with the more talented best friend throwing the exam and sacrificing themselves in order to save their friend's life/any innocence he has left.

Occasionally, it is a Secret Test of Character, in one of two ways. Either you're not supposed to Shoot Your Mate, or you ARE but the gun is loaded with blanks.

Sub-Trope of Involuntary Battle to the Death and Initiation Ceremony. See also Shoot Your Mate and Rite of Passage.

Anime and Manga

 * It used to be part of the Village in the Mist's initiation in Naruto, until Zabuza decided to be a smartass and kill all the other graduates. Before he was even old enough to actually qualify. They probably couldn't spare any future ninja past that point, especially since they had such a test to compensate for their small population.
 * Burst Angel has the Genocide Angels killing each other until only one remains... or at least they were supposed to: their final test is interrupted, they end up scattered around the world, and now Jo is pestered by the two remaining survivors who are there to kill her.

Comic Books

 * The Star Wars comic Crimson Empire has this as the final exam for Royal Guards.
 * And in the first Knights of the Old Republic, this is the final test for up-and-coming Sith.
 * In the Granny Goodness backstory her final exam was to kill the loyal dog she had trained. She avoided this by killing the examiner. Darkseid later forced her to complete the test by siccing the dog on her.

Film

 * In the movie Azumi, the ten young assassin students were told to pair up with the person they liked the most before their final exam. Then they were told to fight each other to the death. (This conveniently killed off half of the cast before the movie even began properly.)
 * The Wong Jing film Naked Weapon does this particularly graphically, and variations have cropped up in other Category III films.
 * The opening montage of the Korean movie Shiri shows North Korean assassins going through a hellish training program and initiation. In one test, the cadets are made to bayonet a field full of civilians who are tied to stakes. One man shows remorse afterwards and is killed. In another, cadets are paired up and each given a disassembled pistol. The first one to correctly assemble it must shoot their partner.

Literature

 * The Unsullied eunuch slave soldiers in A Song of Ice and Fire are given a puppy to raise that after a year they have to kill. To actually become Unsullied they are sent to kill a slave child. It's mentioned that they have a harder time with the puppy test than the child one; those that fail are killed and fed to the surviving puppies.
 * On Gor this is the final test to join the Caste of Assassins.
 * Discworld: Pyramids includes a graduation test for Pteppic, in which he's supposed to assassinate someone who is sleeping in a room "guarded" by one of his teachers. Pteppic is terrified by the idea of actually killing someone, however, and ends up firing his crossbow at nothing rather than kill (but still hits the target due to a "lucky" shot). It turns out to just be a dummy under a sheet.
 * Another student, however, discovers under the sheet a student who had failed the exam. Since it's after the fact, this isn't a Shoot Your Mate order.
 * They're also perfectly allowed to inhume the examiners... but the savvy ones don't tend to risk it.
 * In the first book of the Emperor series this happens to Gaius and Marcus after Renius spent years training them. Only in this case their graduation is to fight Renius himself, veteran warrior and gladiator, to the death.
 * Charles Stross's story Palimpsest has a unique variation: the final test for a time agent is to go back in time and murder yourself.

Stand-Up Comedy

 * The loaded-with-blanks version is a classic Black Comedy anecdote. Three cadets are training to be in the FBI. In the final test they are each lead into a room with their spouse bound and gagged. They're given a gun and told to kill them. One walks out right away saying he can't do it. Another stays in the room longer, but eventually walks out saying he couldn't do it either. They are both told that it was a test of loyalty and they failed. The third stays in the room much longer, eventually leaving and saying "Some idiot loaded the gun with blanks so I had to strangle him/her."
 * There are of course countless variations of that joke, from CIA recruitment to SAS training, and from strangling to Pistol-Whipping to beating him to death with his chair...

Tabletop Games

 * Dungeons and Dragons carries a pair of any critters, so...
 * It was mentioned as a possible first assignment for a newly trained assassin in the article "The Assassin's Guild" in Dragon magazine #64 (1982).
 * Forgotten Realms drow has Rite of Passage called "The Blooding". In the usual variety the young drow have to kill an intelligent and/or dangerous creature from surface. The communities that conduct raids on surface usually hold "the Running" instead - yearly raids during which first-time participants are expected to pass the Blooding.
 * In Homeland one Drizzt Do'Urden faked his Blooding during a raid (the Menzoberranyr do individual ceremony, but apparently not for male minor nobles). This also managed to bite him in the butt, since the one he didn't kill misunderstood it - apparently No Good Deed Goes Unpunished for the drow, or maybe it's just him.
 * Rite of Blood (side-story to Starlight And Shadows in an antology) tells about The Blooding ceremony of Liriel Baenre, who as a member of the ruling House was given a "grand" version, and even had it sabotaged by a rival. But even if she usually doesn't want to, she can do things "the drow way" amusingly well.
 * War of the Spider Queen prologue described the like this: thousands of spiders start killing and eating each other to gain power, but if one grows too much others will team up to get it down, until only the 8 most strong and cunning remain.

Video Games

 * Used as the second Death Knight quest in World of Warcraft - After carving the runes on your weapon, you're told to go kill one of the "unworthy trainees," in a fight to the death.
 * It's also later somewhat reversed in Naxxramas, during the fight with Instructor Rasuvius—you mind-control his trainees and force them to kill him.
 * Apollo Justice: Ace Attorney: Phoenix's case in "Turnabout Succession" involved this. Both Zak and Valant Gramarye were ordered by Magcnifici Garamrye to bring a gun to his hospital room and "shoot straight in the forehead."
 * Non-lethal example in Mortal Kombat 11, Cassie has to fight her CO - that would be Sonya, her own mother - as the final exam for promotion to Commander. Although, given how the fighters in this game are Made of Plasticine, the fight is often rather brutal anyway.

Web Comics

 * Valentino's backstory in the Marilith webcomic. Made even more horrifying since it was not an assassin guild, but a gulag.

Western Animation

 * The episode of The Simpsons "Treehouse of Horror XXV" has Bart attend a school in Hell where he excels at classes in torture and ironic punishments. For his final test, he must torture Homer; despite Bart's hesitation, Homer encourages him to do so, as he's so proud that Bart has actually found his niche. Later, Marge, Lisa, and a disfigured Homer watch him graduate as valeditorian.