#include "catch.hpp"
#include <string.h>
#include <sstream>
#include <math.h>
#include "../printf.h"
#include "../printf.c"
Go to the source code of this file.
Classes | |
struct | test::out_fct_wrap_type |
Namespaces | |
test | |
Macros | |
#define | CATCH_CONFIG_MAIN |
Typedefs | |
typedef void(* | test::out_fct_type) (char character, void *buffer, size_t idx, size_t maxlen) |
Functions | |
static unsigned int | test::_atoi (const char **str) |
static size_t | test::_etoa (out_fct_type out, char *buffer, size_t idx, size_t maxlen, double value, unsigned int prec, unsigned int width, unsigned int flags) |
static size_t | test::_ftoa (out_fct_type out, char *buffer, size_t idx, size_t maxlen, double value, unsigned int prec, unsigned int width, unsigned int flags) |
static bool | test::_is_digit (char ch) |
static size_t | test::_ntoa_format (out_fct_type out, char *buffer, size_t idx, size_t maxlen, char *buf, size_t len, bool negative, unsigned int base, unsigned int prec, unsigned int width, unsigned int flags) |
static size_t | test::_ntoa_long (out_fct_type out, char *buffer, size_t idx, size_t maxlen, unsigned long value, bool negative, unsigned long base, unsigned int prec, unsigned int width, unsigned int flags) |
static size_t | test::_ntoa_long_long (out_fct_type out, char *buffer, size_t idx, size_t maxlen, unsigned long long value, bool negative, unsigned long long base, unsigned int prec, unsigned int width, unsigned int flags) |
static void | test::_out_buffer (char character, void *buffer, size_t idx, size_t maxlen) |
static void | test::_out_char (char character, void *buffer, size_t idx, size_t maxlen) |
void | _out_fct (char character, void *arg) |
static void | test::_out_fct (char character, void *buffer, size_t idx, size_t maxlen) |
static void | test::_out_null (char character, void *buffer, size_t idx, size_t maxlen) |
static size_t | test::_out_rev (out_fct_type out, char *buffer, size_t idx, size_t maxlen, const char *buf, size_t len, unsigned int width, unsigned int flags) |
void | test::_putchar (char character) |
static unsigned int | test::_strnlen_s (const char *str, size_t maxsize) |
static int | test::_vsnprintf (out_fct_type out, char *buffer, const size_t maxlen, const char *format, va_list va) |
int | test::fctprintf (void(*out)(char character, void *arg), void *arg, const char *format,...) |
int | test::printf_ (const char *format,...) |
int | test::snprintf_ (char *buffer, size_t count, const char *format,...) |
int | test::sprintf_ (char *buffer, const char *format,...) |
TEST_CASE ("printf", "[]") | |
TEST_CASE ("fctprintf", "[]") | |
TEST_CASE ("snprintf", "[]") | |
TEST_CASE ("vprintf", "[]") | |
TEST_CASE ("vsnprintf", "[]") | |
TEST_CASE ("space flag", "[]") | |
TEST_CASE ("+ flag", "[]") | |
TEST_CASE ("0 flag", "[]") | |
TEST_CASE ("- flag", "[]") | |
TEST_CASE ("# flag", "[]") | |
TEST_CASE ("specifier", "[]") | |
TEST_CASE ("width", "[]") | |
TEST_CASE ("width 20", "[]") | |
TEST_CASE ("width *20", "[]") | |
TEST_CASE ("width -20", "[]") | |
TEST_CASE ("width 0-20", "[]") | |
TEST_CASE ("padding 20", "[]") | |
TEST_CASE ("padding .20", "[]") | |
TEST_CASE ("padding #020", "[]") | |
TEST_CASE ("padding #20", "[]") | |
TEST_CASE ("padding 20.5", "[]") | |
TEST_CASE ("padding neg numbers", "[]") | |
TEST_CASE ("float padding neg numbers", "[]") | |
TEST_CASE ("length", "[]") | |
TEST_CASE ("float", "[]") | |
TEST_CASE ("types", "[]") | |
TEST_CASE ("pointer", "[]") | |
TEST_CASE ("unknown flag", "[]") | |
TEST_CASE ("string length", "[]") | |
TEST_CASE ("buffer length", "[]") | |
TEST_CASE ("ret value", "[]") | |
TEST_CASE ("misc", "[]") | |
int | test::vprintf_ (const char *format, va_list va) |
static void | vprintf_builder_1 (char *buffer,...) |
int | test::vsnprintf_ (char *buffer, size_t count, const char *format, va_list va) |
static void | vsnprintf_builder_1 (char *buffer,...) |
static void | vsnprintf_builder_3 (char *buffer,...) |
Variables | |
static char | printf_buffer [100] |
static size_t | printf_idx = 0U |
#define CATCH_CONFIG_MAIN |
Definition at line 30 of file test_suite.cpp.
void _out_fct | ( | char | character, |
void * | arg | ||
) |
Definition at line 54 of file test_suite.cpp.
TEST_CASE | ( | "printf" | , |
"" | [] | ||
) |
Definition at line 61 of file test_suite.cpp.
TEST_CASE | ( | "fctprintf" | , |
"" | [] | ||
) |
Definition at line 71 of file test_suite.cpp.
TEST_CASE | ( | "snprintf" | , |
"" | [] | ||
) |
Definition at line 80 of file test_suite.cpp.
TEST_CASE | ( | "vprintf" | , |
"" | [] | ||
) |
Definition at line 115 of file test_suite.cpp.
TEST_CASE | ( | "vsnprintf" | , |
"" | [] | ||
) |
Definition at line 126 of file test_suite.cpp.
TEST_CASE | ( | "space flag" | , |
"" | [] | ||
) |
Definition at line 137 of file test_suite.cpp.
TEST_CASE | ( | "+ flag" | , |
"" | [] | ||
) |
Definition at line 211 of file test_suite.cpp.
TEST_CASE | ( | "0 flag" | , |
"" | [] | ||
) |
Definition at line 279 of file test_suite.cpp.
TEST_CASE | ( | "- flag" | , |
"" | [] | ||
) |
Definition at line 314 of file test_suite.cpp.
TEST_CASE | ( | "# flag" | , |
"" | [] | ||
) |
Definition at line 387 of file test_suite.cpp.
TEST_CASE | ( | "specifier" | , |
"" | [] | ||
) |
Definition at line 403 of file test_suite.cpp.
TEST_CASE | ( | "width" | , |
"" | [] | ||
) |
Definition at line 453 of file test_suite.cpp.
TEST_CASE | ( | "width 20" | , |
"" | [] | ||
) |
Definition at line 500 of file test_suite.cpp.
TEST_CASE | ( | "width *20" | , |
"" | [] | ||
) |
Definition at line 547 of file test_suite.cpp.
TEST_CASE | ( | "width -20" | , |
"" | [] | ||
) |
Definition at line 594 of file test_suite.cpp.
TEST_CASE | ( | "width 0-20" | , |
"" | [] | ||
) |
Definition at line 656 of file test_suite.cpp.
TEST_CASE | ( | "padding 20" | , |
"" | [] | ||
) |
Definition at line 703 of file test_suite.cpp.
TEST_CASE | ( | "padding .20" | , |
"" | [] | ||
) |
Definition at line 744 of file test_suite.cpp.
TEST_CASE | ( | "padding #020" | , |
"" | [] | ||
) |
Definition at line 785 of file test_suite.cpp.
TEST_CASE | ( | "padding #20" | , |
"" | [] | ||
) |
Definition at line 826 of file test_suite.cpp.
TEST_CASE | ( | "padding 20.5" | , |
"" | [] | ||
) |
Definition at line 867 of file test_suite.cpp.
TEST_CASE | ( | "padding neg numbers" | , |
"" | [] | ||
) |
Definition at line 908 of file test_suite.cpp.
TEST_CASE | ( | "float padding neg numbers" | , |
"" | [] | ||
) |
Definition at line 939 of file test_suite.cpp.
TEST_CASE | ( | "length" | , |
"" | [] | ||
) |
Definition at line 995 of file test_suite.cpp.
TEST_CASE | ( | "float" | , |
"" | [] | ||
) |
Definition at line 1078 of file test_suite.cpp.
TEST_CASE | ( | "types" | , |
"" | [] | ||
) |
Definition at line 1242 of file test_suite.cpp.
TEST_CASE | ( | "pointer" | , |
"" | [] | ||
) |
Definition at line 1359 of file test_suite.cpp.
TEST_CASE | ( | "unknown flag" | , |
"" | [] | ||
) |
Definition at line 1397 of file test_suite.cpp.
TEST_CASE | ( | "string length" | , |
"" | [] | ||
) |
Definition at line 1405 of file test_suite.cpp.
TEST_CASE | ( | "buffer length" | , |
"" | [] | ||
) |
Definition at line 1431 of file test_suite.cpp.
TEST_CASE | ( | "ret value" | , |
"" | [] | ||
) |
Definition at line 1454 of file test_suite.cpp.
TEST_CASE | ( | "misc" | , |
"" | [] | ||
) |
Definition at line 1482 of file test_suite.cpp.
|
static |
Definition at line 90 of file test_suite.cpp.
|
static |
Definition at line 98 of file test_suite.cpp.
|
static |
Definition at line 106 of file test_suite.cpp.
|
static |
Definition at line 46 of file test_suite.cpp.
|
static |
Definition at line 47 of file test_suite.cpp.