That waxy thing that you eat the bean and spit out the skin is called a tremoço. In Portugal tremolos, or Lupini Beans, are a salty snack. You enjoy them by removing the skin in your mouth and tossing the waxy skin away. Tremoços are great with a beer (Sagres or Super Bock).
Most cafes will serve them by the plate with a beer, as they are perfect to as a beer accompaniment on a sunny day, and the shells are loved by pigeons.