You are here

function Braintree_WebhookNotificationTest::testParsingModifiedSignatureRaisesError in Commerce Braintree 7

File

braintree_php/tests/unit/WebhookNotificationTest.php, line 29

Class

Braintree_WebhookNotificationTest

Code

function testParsingModifiedSignatureRaisesError() {
  $sampleNotification = Braintree_WebhookTesting::sampleNotification(Braintree_WebhookNotification::SUBSCRIPTION_WENT_PAST_DUE, 'my_id');
  $this
    ->setExpectedException('Braintree_Exception_InvalidSignature');
  $webhookNotification = Braintree_WebhookNotification::parse($sampleNotification['signature'] . "bad", $sampleNotification['payload']);
}