Asserts the existence of a button with a certain ID and label.
string $id: The HTML ID of the button
string $label.: The expected label for the button.
string $message: (optional) A custom message to display with the assertion. If no custom message is provided, the message will indicate the button label.
bool TRUE if the asserion was succesful, or FALSE on failure.
protected function helperButtonHasLabel($id, $expected_label, $message = 'Label has the expected value: %label.') {
return $this
->assertFieldById($id, $expected_label, t($message, array(
'%label' => $expected_label,
)));
}