Staying and being asked to train my peer who was given the promotion that I felt I was by far the better candidate for. Sour grapes or not, I was the only opportunity I was going to have to move up for the foreseeable future. It was a small department.
In the end it worked out amazingly for me, despite some bumps.
Good luck.