Robin is nominated to receive an award for a news report and everyone needs a date to take to the show. Barney introduces Ted to Mary as a date that Ted can take to the show. Originally Ted is opposed to the idea of just trying to save face in front of Robin but when she shows up with a date he changes his mind. Robin asks Mary lots of questions, and Ted begins to really like Mary, despite her occupation.
Image source: themoviedb.org