Pain is defined by humans as a highly unpleasant physical sensation caused by illness or injury—something that humans usually try to avoid.
Plants, like humans, want to avoid illness or injury. In the light of this, plants feel pain. They have a defensive mechanism that allows them to secrete compounds that can warn nearby plants that a threat is nearby. These plants respond by defending themselves through, for one thing, the production of sour tasting toxins that cause the herbivore discomfort (meaning, for example, that goats end up with upset stomachs).
So plants do feel ‘pain’ and have evolved to react to it—food for thought.