syslog-ng source
test_python_template.c File Reference
#include "python-module.h"
#include <criterion/criterion.h>
#include "python-helpers.h"
#include "python-types.h"
#include "python-logmsg.h"
#include "python-logtemplate.h"
#include "python-logtemplate-options.h"
#include "python-main.h"
#include "python-startup.h"
#include "apphook.h"
#include "logmsg/logmsg.h"
#include "syslog-format.h"
#include "timeutils/format.h"
#include "cfg.h"
#include "scratch-buffers.h"
#include "python-integerpointer.h"
Include dependency graph for test_python_template.c:

Functions

void setup (void)
 
void teardown (void)
 
 TestSuite (python_log_logtemplate,.init=setup,.fini=teardown)
 
void assert_format (gchar *expected, PyLogTemplate *template, PyLogMessage *msg)
 
 Test (python_log_logtemplate, test_python_template)
 
 Test (python_log_logtemplate, test_no_template_options_via_either_constructor_or_format_causes_an_exception)
 
 Test (python_log_logtemplate, format_all_parameters)
 
 Test (python_log_logtemplate, test_logtemplate_exception)
 
 Test (python_log_logtemplate, test_py_is_log_template_options)
 
 Test (python_log_logtemplate, test_integerpointer)
 

Variables

LogTemplateOptions log_template_options
 
PyObject * py_template_options
 

Function Documentation

◆ assert_format()

void assert_format ( gchar *  expected,
PyLogTemplate template,
PyLogMessage msg 
)

◆ setup()

void setup ( void  )

◆ teardown()

void teardown ( void  )

◆ Test() [1/6]

Test ( python_log_logtemplate  ,
format_all_parameters   
)

◆ Test() [2/6]

Test ( python_log_logtemplate  ,
test_integerpointer   
)

◆ Test() [3/6]

Test ( python_log_logtemplate  ,
test_logtemplate_exception   
)

◆ Test() [4/6]

Test ( python_log_logtemplate  ,
test_no_template_options_via_either_constructor_or_format_causes_an_exception   
)

◆ Test() [5/6]

Test ( python_log_logtemplate  ,
test_py_is_log_template_options   
)

◆ Test() [6/6]

Test ( python_log_logtemplate  ,
test_python_template   
)

◆ TestSuite()

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

Variable Documentation

◆ log_template_options

LogTemplateOptions log_template_options

◆ py_template_options

PyObject* py_template_options