1 Kings 2:42

42 he summoned Shimei. Solomon asked him, "Didn't I make you take an oath by the LORD? Didn't I warn you that if you left [the city] to go anywhere, you could be certain that you would die? Didn't you say to me, 'Very well. I'll do just what you said'?