syslog-ng source
test_file_opener.c File Reference
#include <criterion/criterion.h>
#include "file-opener.h"
#include "named-pipe.h"
#include "file-specializations.h"
#include "messages.h"
#include "apphook.h"
#include <fcntl.h>
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <sys/stat.h>
#include <unistd.h>
#include <errno.h>
Include dependency graph for test_file_opener.c:

Macros

#define CREATE_DIRS   0x01
 
#define SRC_FILE   0x02
 
#define DST_FILE   0x04
 

Functions

 Test (file_opener, test_open_regular_file)
 
 Test (file_opener, test_open_named_pipe)
 
 Test (file_opener, test_spurious_path)
 
 Test (file_opener, test_create_file_in_nonexistent_dir)
 
 Test (file_opener, test_file_flags)
 
void teardown (void)
 
 TestSuite (file_opener,.init=setup,.fini=teardown)
 

Macro Definition Documentation

◆ CREATE_DIRS

#define CREATE_DIRS   0x01

◆ DST_FILE

#define DST_FILE   0x04

◆ SRC_FILE

#define SRC_FILE   0x02

Function Documentation

◆ teardown()

void teardown ( void  )

◆ Test() [1/5]

Test ( file_opener  ,
test_create_file_in_nonexistent_dir   
)

◆ Test() [2/5]

Test ( file_opener  ,
test_file_flags   
)

◆ Test() [3/5]

Test ( file_opener  ,
test_open_named_pipe   
)

◆ Test() [4/5]

Test ( file_opener  ,
test_open_regular_file   
)

◆ Test() [5/5]

Test ( file_opener  ,
test_spurious_path   
)

◆ TestSuite()

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