Skip to content
This repository was archived by the owner on Oct 22, 2019. It is now read-only.

Commit b73b453

Browse files
author
Marko Kruljac
committed
added tests
1 parent 283c9b6 commit b73b453

4 files changed

Lines changed: 77 additions & 0 deletions

File tree

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?php
2+
3+
4+
namespace Test\Prometheus\InMemory;
5+
6+
use Prometheus\Storage\InMemory;
7+
use Test\Prometheus\AbstractCollectorRegistryTest;
8+
9+
class CollectorRegistryTest extends AbstractCollectorRegistryTest
10+
{
11+
public function configureAdapter()
12+
{
13+
$this->adapter = new InMemory();
14+
$this->adapter->flushMemory();
15+
}
16+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<?php
2+
3+
4+
namespace Test\Prometheus\InMemory;
5+
6+
use Prometheus\Storage\InMemory;
7+
use Test\Prometheus\AbstractCounterTest;
8+
9+
/**
10+
* See https://prometheus.io/docs/instrumenting/exposition_formats/
11+
*/
12+
class CounterTest extends AbstractCounterTest
13+
{
14+
15+
public function configureAdapter()
16+
{
17+
$this->adapter = new InMemory();
18+
$this->adapter->flushMemory();
19+
}
20+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<?php
2+
3+
4+
namespace Test\Prometheus\InMemory;
5+
6+
use Prometheus\Storage\InMemory;
7+
use Test\Prometheus\AbstractGaugeTest;
8+
9+
/**
10+
* See https://prometheus.io/docs/instrumenting/exposition_formats/
11+
*/
12+
class GaugeTest extends AbstractGaugeTest
13+
{
14+
15+
public function configureAdapter()
16+
{
17+
$this->adapter = new InMemory();
18+
$this->adapter->flushMemory();
19+
}
20+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<?php
2+
3+
4+
namespace Test\Prometheus\InMemory;
5+
6+
use Prometheus\Storage\InMemory;
7+
use Test\Prometheus\AbstractHistogramTest;
8+
9+
/**
10+
* See https://prometheus.io/docs/instrumenting/exposition_formats/
11+
*/
12+
class HistogramTest extends AbstractHistogramTest
13+
{
14+
15+
public function configureAdapter()
16+
{
17+
$this->adapter = new InMemory();
18+
$this->adapter->flushMemory();
19+
}
20+
}
21+

0 commit comments

Comments
 (0)