Skip to content

Commit 1bd7751

Browse files
committed
update_last_request_at on createUser calls too.
1 parent f94d303 commit 1bd7751

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

src/Intercom/Service/config/intercom_public_user.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,11 @@
102102
"required": false,
103103
"type": "boolean"
104104
},
105+
"update_last_request_at": {
106+
"location": "json",
107+
"required": false,
108+
"type": "boolean"
109+
},
105110
"user_id": {
106111
"location": "json",
107112
"required": false,

tests/Intercom/Resources/UserTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@ public function testGetUserByUserID()
3535
public function testCreateUser()
3636
{
3737
$this->setMockResponse($this->client, 'User/User.txt');
38-
$response = $this->client->createUser(['name' => 'Joe Schmoe', 'email' => '[email protected]', 'hi' => 'hello']);
38+
$response = $this->client->createUser(['name' => 'Joe Schmoe', 'email' => '[email protected]', 'hi' => 'hello', 'update_last_request_at' => true]);
3939

4040
$this->assertRequest('POST', '/users');
41-
$this->assertRequestJson(['email' => '[email protected]', 'name' => 'Joe Schmoe']);
41+
$this->assertRequestJson(['email' => '[email protected]', 'name' => 'Joe Schmoe', 'update_last_request_at' => true]);
4242

4343
$this->assertInstanceOf('\Guzzle\Service\Resource\Model', $response);
4444
$this->assertEquals('Joe Schmoe', $response['name']);
@@ -124,4 +124,4 @@ public function testUpdateUserNoID()
124124
{
125125
$this->client->updateUser();
126126
}
127-
}
127+
}

0 commit comments

Comments
 (0)