-
Notifications
You must be signed in to change notification settings - Fork 144
Expand file tree
/
Copy pathIntercomDataAttributeTest.php
More file actions
38 lines (29 loc) · 1.07 KB
/
IntercomDataAttributeTest.php
File metadata and controls
38 lines (29 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php
namespace Intercom\Test;
use Intercom\IntercomDataAttribute;
class IntercomDataAttributeTest extends TestCase
{
public function testDataAttributeCreate()
{
$this->client->method('post')->willReturn('foo');
$dataAttributes = new IntercomDataAttribute($this->client);
$this->assertSame('foo', $dataAttributes->create([]));
}
public function testDataAttributeUpdate()
{
$this->client->method('put')->willReturn('foo');
$dataAttribute = new IntercomDataAttribute($this->client);
$this->assertSame('foo', $dataAttribute->update('', []));
}
public function testDataAttributesGet()
{
$this->client->method('get')->willReturn('foo');
$dataAttributes = new IntercomDataAttribute($this->client);
$this->assertSame('foo', $dataAttributes->getDataAttributes([]));
}
public function testDataAttributesGetPath()
{
$dataAttributes = new IntercomDataAttribute($this->client);
$this->assertSame('data_attributes/1', $dataAttributes->dataAttributePath('1'));
}
}