There can be many different metrics that can define friendship.
What is offered here is only a guide. Your own experience and reflection are going to be critical elements in defining friendship. I think that one aspect of friendship has to be commitment to another person. A true friendship involves being able to stand up for one another. I believe that you know someone is your friend in their willingness to support you. This might take the form of supporting your dreams and hopes. It might take the form of emotionally assisting you when you are feeling weak.
Another key element to true friendship is dependent on circumstance. I think that true friendship emerges during difficult situations. It is easy to be a friend when times are good. When people are popular or wealthy, they seem to have an abundance of "friends." However, true friendship is evident when people experience difficult times. The people who support you unconditionally during these moments probably are displaying tenets of good friendship. You know someone is a true friend when they stay awake through the night when you are worried about something or when they continually visit while you are in the hospital. When the weight of the world seems to be crushing the individual, a true friend will be there to assist with the heavy lifting. I think that taking stock of who is with you during these moments is an ingredient behind figuring out whether someone is a true friend.