RetroArch
Classes | Macros | Functions
valuetest.cpp File Reference
#include "unittest.h"
#include "rapidjson/document.h"
#include <algorithm>
Include dependency graph for valuetest.cpp:

Classes

struct  TerminateHandler< e >
 
struct  ValueIntComparer
 

Macros

#define TEST_TERMINATION(e, json)
 

Functions

 TEST (Value, Size)
 
 TEST (Value, DefaultConstructor)
 
 TEST (Value, AssignmentOperator)
 
template<typename A , typename B >
void TestEqual (const A &a, const B &b)
 
template<typename A , typename B >
void TestUnequal (const A &a, const B &b)
 
 TEST (Value, EqualtoOperator)
 
template<typename Value >
void TestCopyFrom ()
 
 TEST (Value, CopyFrom)
 
 TEST (Value, Swap)
 
 TEST (Value, Null)
 
 TEST (Value, True)
 
 TEST (Value, False)
 
 TEST (Value, Int)
 
 TEST (Value, Uint)
 
 TEST (Value, Int64)
 
 TEST (Value, Uint64)
 
 TEST (Value, Double)
 
 TEST (Value, Float)
 
 TEST (Value, IsLosslessDouble)
 
 TEST (Value, IsLosslessFloat)
 
 TEST (Value, String)
 
 TEST (Value, SetStringNullException)
 
template<typename T , typename Allocator >
static void TestArray (T &x, Allocator &allocator)
 
 TEST (Value, Array)
 
 TEST (Value, ArrayHelper)
 
template<typename T , typename Allocator >
static void TestObject (T &x, Allocator &allocator)
 
 TEST (Value, Object)
 
 TEST (Value, ObjectHelper)
 
 TEST (Value, EraseMember_String)
 
 TEST (Value, BigNestedArray)
 
 TEST (Value, BigNestedObject)
 
 TEST (Value, RemoveLastElement)
 
 TEST (Document, CrtAllocator)
 
static void TestShortStringOptimization (const char *str)
 
 TEST (Value, AllocateShortString)
 
 TEST (Value, AcceptTerminationByHandler)
 
static void MergeDuplicateKey (Value &v, Value::AllocatorType &a)
 
 TEST (Value, MergeDuplicateKey)
 

Macro Definition Documentation

◆ TEST_TERMINATION

#define TEST_TERMINATION (   e,
  json 
)
Value:
{\
Document d; \
EXPECT_FALSE(d.Parse(json).HasParseError()); \
Reader reader; \
TerminateHandler<e> h;\
EXPECT_FALSE(d.Accept(h));\
}
static const char * reader(lua_State *L, void *ud, size_t *size)
Definition: luac.c:122
static const char json[]
Definition: namespacetest.cpp:32
GLfloat GLfloat GLfloat GLfloat h
Definition: glext.h:8390

Function Documentation

◆ MergeDuplicateKey()

static void MergeDuplicateKey ( Value v,
Value::AllocatorType a 
)
static
Here is the caller graph for this function:

◆ TEST() [1/31]

TEST ( Value  ,
Size   
)

◆ TEST() [2/31]

TEST ( Value  ,
DefaultConstructor   
)

◆ TEST() [3/31]

TEST ( Value  ,
AssignmentOperator   
)
Here is the call graph for this function:

◆ TEST() [4/31]

TEST ( Value  ,
EqualtoOperator   
)
Here is the call graph for this function:

◆ TEST() [5/31]

TEST ( Value  ,
CopyFrom   
)

◆ TEST() [6/31]

TEST ( Value  ,
Swap   
)
Here is the call graph for this function:

◆ TEST() [7/31]

TEST ( Value  ,
Null   
)

◆ TEST() [8/31]

TEST ( Value  ,
True   
)

◆ TEST() [9/31]

TEST ( Value  ,
False   
)

◆ TEST() [10/31]

TEST ( Value  ,
Int   
)

◆ TEST() [11/31]

TEST ( Value  ,
Uint   
)

◆ TEST() [12/31]

TEST ( Value  ,
Int64   
)

◆ TEST() [13/31]

TEST ( Value  ,
Uint64   
)

◆ TEST() [14/31]

TEST ( Value  ,
Double   
)

◆ TEST() [15/31]

TEST ( Value  ,
Float   
)

◆ TEST() [16/31]

TEST ( Value  ,
IsLosslessDouble   
)

◆ TEST() [17/31]

TEST ( Value  ,
IsLosslessFloat   
)

◆ TEST() [18/31]

TEST ( Value  ,
String   
)
Here is the call graph for this function:

◆ TEST() [19/31]

TEST ( Value  ,
SetStringNullException   
)

◆ TEST() [20/31]

TEST ( Value  ,
Array   
)
Here is the call graph for this function:

◆ TEST() [21/31]

TEST ( Value  ,
ArrayHelper   
)
Here is the call graph for this function:

◆ TEST() [22/31]

TEST ( Value  ,
Object   
)
Here is the call graph for this function:

◆ TEST() [23/31]

TEST ( Value  ,
ObjectHelper   
)
Here is the call graph for this function:

◆ TEST() [24/31]

TEST ( Value  ,
EraseMember_String   
)

◆ TEST() [25/31]

TEST ( Value  ,
BigNestedArray   
)
Here is the call graph for this function:

◆ TEST() [26/31]

TEST ( Value  ,
BigNestedObject   
)
Here is the call graph for this function:

◆ TEST() [27/31]

TEST ( Value  ,
RemoveLastElement   
)

◆ TEST() [28/31]

TEST ( Document  ,
CrtAllocator   
)

◆ TEST() [29/31]

TEST ( Value  ,
AllocateShortString   
)
Here is the call graph for this function:

◆ TEST() [30/31]

TEST ( Value  ,
AcceptTerminationByHandler   
)

◆ TEST() [31/31]

TEST ( Value  ,
MergeDuplicateKey   
)
Here is the call graph for this function:

◆ TestArray()

template<typename T , typename Allocator >
static void TestArray ( T x,
Allocator allocator 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ TestCopyFrom()

template<typename Value >
void TestCopyFrom ( )

◆ TestEqual()

template<typename A , typename B >
void TestEqual ( const A a,
const B b 
)
Here is the caller graph for this function:

◆ TestObject()

template<typename T , typename Allocator >
static void TestObject ( T x,
Allocator allocator 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ TestShortStringOptimization()

static void TestShortStringOptimization ( const char *  str)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ TestUnequal()

template<typename A , typename B >
void TestUnequal ( const A a,
const B b 
)
Here is the caller graph for this function: