A martyr is one who is killed for his faith. Only two individuals are specifically named as martyrs in scripture: Stephen and Antipas.
Capital punishment is not confined to the Old Testament and is not done to the exclusion of God’s grace, but rather as an act of God’s just judgment.