Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/Requests/MailchimpRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,7 @@ public function getHeaders()
if (!is_array($this->headers)) {
throw new MailchimpException("Request headers must be of type array");
}
$this->headers[] = 'Expect:';
return $this->headers;
}

Expand Down
7 changes: 7 additions & 0 deletions tests/UtilityTests/MailchimpRequestTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,13 @@ public function testAuthHeadersSet()
self::assertEquals($expected, $actual, "Auth Header should be appropriately set");
}

public function testExpectHeaderNotSet()
{
$expected = 'Expect:';
$actual = $this->requestInstance->getHeaders()[1];
self::assertEquals($expected, $actual, "Expect header should be empty");
}

public function testApikeySet()
{
self::assertEquals(
Expand Down