syslog-ng source
test_stats_prometheus.c File Reference
#include <criterion/criterion.h>
#include "stats/stats.h"
#include "stats/stats-cluster.h"
#include "stats/stats-cluster-single.h"
#include "stats/stats-cluster-logpipe.h"
#include "stats/stats-prometheus.h"
#include "timeutils/unixtime.h"
#include "scratch-buffers.h"
#include "mainloop.h"
#include "apphook.h"
#include "libtest/fake-time.h"
#include <float.h>
#include <limits.h>
Include dependency graph for test_stats_prometheus.c:

Functions

 TestSuite (stats_prometheus,.init=setup,.fini=teardown)
 
 Test (stats_prometheus, test_prometheus_format_single)
 
 Test (stats_prometheus, test_prometheus_format_logpipe)
 
 Test (stats_prometheus, test_prometheus_format_empty_label_value)
 
 Test (stats_prometheus, test_prometheus_format_sanitize)
 
 Test (stats_prometheus, test_prometheus_format_label_escaping)
 
gchar * stats_format_prometheus_format_value (const StatsClusterKey *key, const StatsCounterItem *counter)
 
 Test (stats_prometheus, test_prometheus_format_value)
 
 Test (stats_prometheus, test_prometheus_format_legacy)
 
 Test (stats_prometheus, test_prometheus_format_legacy_alias_is_ignored)
 

Function Documentation

◆ stats_format_prometheus_format_value()

gchar* stats_format_prometheus_format_value ( const StatsClusterKey *  key,
const StatsCounterItem counter 
)

◆ Test() [1/8]

Test ( stats_prometheus  ,
test_prometheus_format_empty_label_value   
)

◆ Test() [2/8]

Test ( stats_prometheus  ,
test_prometheus_format_label_escaping   
)

◆ Test() [3/8]

Test ( stats_prometheus  ,
test_prometheus_format_legacy   
)

◆ Test() [4/8]

Test ( stats_prometheus  ,
test_prometheus_format_legacy_alias_is_ignored   
)

◆ Test() [5/8]

Test ( stats_prometheus  ,
test_prometheus_format_logpipe   
)

◆ Test() [6/8]

Test ( stats_prometheus  ,
test_prometheus_format_sanitize   
)

◆ Test() [7/8]

Test ( stats_prometheus  ,
test_prometheus_format_single   
)

◆ Test() [8/8]

Test ( stats_prometheus  ,
test_prometheus_format_value   
)

◆ TestSuite()

TestSuite ( stats_prometheus  ,
init = setup,
fini = teardown 
)