Skip to content

Commit 8a23d7d

Browse files
committed
test update user with no id
1 parent da93045 commit 8a23d7d

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

tests/Intercom/Resources/UserTest.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -118,11 +118,12 @@ public function testGetUsersBySegmentID()
118118
$this->assertRequest('GET', '/users?segment_id=20');
119119
}
120120

121-
/**
122-
* @expectedException \Guzzle\Service\Exception\ValidationException
123-
*/
124121
public function testUpdateUserNoID()
125122
{
126-
$this->client->updateUser();
123+
$this->setMockResponse($this->client, 'User/User.txt');
124+
$response = $this->client->updateUser(['user_id' => '1234', 'hi' => 'hello', 'new_session' => true]);
125+
126+
$this->assertRequest('POST', '/users');
127+
$this->assertRequestJson(['user_id' => '1234', 'new_session' => true]);
127128
}
128129
}

0 commit comments

Comments
 (0)