Nilorea Library
C utilities for networking, threading, graphics
Loading...
Searching...
No Matches
ex_pretty.c File Reference
#include "nilorea/n_common.h"
#include "nilorea/n_log.h"
#include "nilorea/n_pretty.h"
#include "nilorea/n_str.h"
#include <stdio.h>
#include <string.h>
#include <unistd.h>
+ Include dependency graph for ex_pretty.c:

Go to the source code of this file.

Functions

static void expect_contains (const char *label, const N_STR *out, const char *needle)
 
static void expect_true (const char *label, int cond)
 
int main (int argc, char **argv)
 
static void process_args (int argc, char **argv)
 

Variables

static int failures = 0
 

Function Documentation

◆ expect_contains()

static void expect_contains ( const char *  label,
const N_STR out,
const char *  needle 
)
static
Examples
ex_pretty.c.

Definition at line 76 of file ex_pretty.c.

References N_STR::data, failures, LOG_ERR, and n_log.

Referenced by main().

+ Here is the caller graph for this function:

◆ expect_true()

static void expect_true ( const char *  label,
int  cond 
)
static

Definition at line 69 of file ex_pretty.c.

References failures, LOG_ERR, and n_log.

◆ main()

int main ( int  argc,
char **  argv 
)

Definition at line 84 of file ex_pretty.c.

References expect_contains(), expect_true(), failures, free_nstr, LOG_ERR, n_log, n_pretty_js(), n_pretty_json(), n_pretty_xml(), process_args(), and set_log_level().

+ Here is the call graph for this function:

◆ process_args()

static void process_args ( int  argc,
char **  argv 
)
static

Definition at line 39 of file ex_pretty.c.

References LOG_DEBUG, LOG_ERR, LOG_INFO, LOG_NOTICE, LOG_NULL, and set_log_level().

+ Here is the call graph for this function:

Variable Documentation

◆ failures

int failures = 0
static

Definition at line 36 of file ex_pretty.c.