You are here

public function MailchimpListsTest::testUpdateMember in Mailchimp 8

Tests library functionality for updating a list member.

File

lib/mailchimp-api-php/tests/MailchimpListsTest.php, line 176

Class

MailchimpListsTest
Mailchimp Lists test library.

Namespace

Mailchimp\Tests

Code

public function testUpdateMember() {
  $list_id = '57afe96172';
  $email = 'test@example.com';
  $mc = new MailchimpLists();
  $mc
    ->updateMember($list_id, $email);
  $this
    ->assertEquals('PATCH', $mc
    ->getClient()->method);
  $this
    ->assertEquals($mc
    ->getEndpoint() . '/lists/' . $list_id . '/members/' . md5($email), $mc
    ->getClient()->uri);
}