SetTest::testSet()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * This file is part of graze/dog-statsd
4
 *
5
 * Copyright (c) 2016 Nature Delivered Ltd. <https://www.graze.com>
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 *
10
 * @license https://github.com/graze/dog-statsd/blob/master/LICENSE.md
11
 * @link    https://github.com/graze/dog-statsd
12
 */
13
14
namespace Graze\DogStatsD\Test\Unit;
15
16
use Graze\DogStatsD\Test\TestCase;
17
18
class SetTest extends TestCase
19
{
20
    public function testSet()
21
    {
22
        $this->client->set('test_metric', 456);
23
        $this->assertEquals('test_metric:456|s', $this->client->getLastMessage());
24
    }
25
26
    public function testTags()
27
    {
28
        $this->client->set('test_metric', 456, ['tag']);
29
        $this->assertEquals('test_metric:456|s|#tag', $this->client->getLastMessage());
30
    }
31
}
32