NCBI C++ ToolKit
Classes | Macros | Typedefs | Enumerations | Functions | Variables
testodbc.c File Reference
#include "common.h"
#include <common/test_assert.h>
+ Include dependency graph for testodbc.c:

Go to the source code of this file.

Go to the SVN repository for this file.

Classes

struct  DbTestEntry
 

Macros

#define AB_FUNCT(x)
 
#define AB_PRINT(x)
 
#define AB_ERROR(x)   do { printf("ERROR: "); printf x; printf("\n"); } while(0)
 

Typedefs

typedef int DbTestFn(void)
 

Enumerations

enum  { FALSE , TRUE }
 

Functions

static int RunTests (void)
 Code to iterate through all tests to run. More...
 
static int TestRawODBCPreparedQuery (void)
 
static int TestRawODBCDirectQuery (void)
 
static int TestRawODBCGuid (void)
 
int main (int argc, char *argv[])
 

Variables

static DbTestEntry _dbTests []
 Array of tests. More...
 
static DbTestEntrytests = _dbTests
 

Macro Definition Documentation

◆ AB_ERROR

#define AB_ERROR (   x)    do { printf("ERROR: "); printf x; printf("\n"); } while(0)

Definition at line 22 of file testodbc.c.

◆ AB_FUNCT

#define AB_FUNCT (   x)

Definition at line 19 of file testodbc.c.

◆ AB_PRINT

#define AB_PRINT (   x)

Definition at line 20 of file testodbc.c.

Typedef Documentation

◆ DbTestFn

typedef int DbTestFn(void)

Definition at line 28 of file testodbc.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
FALSE 
TRUE 

Definition at line 26 of file testodbc.c.

Function Documentation

◆ main()

int main ( int  argc,
char *  argv[] 
)

Definition at line 429 of file testodbc.c.

References odbc_use_version3, and RunTests().

◆ RunTests()

static int RunTests ( void  )
static

Code to iterate through all tests to run.

Returns
TRUE if all tests pass, FALSE if any tests fail.

Definition at line 397 of file testodbc.c.

References i, ODBC_FREE, and tests.

Referenced by main().

◆ TestRawODBCDirectQuery()

static int TestRawODBCDirectQuery ( void  )
static

◆ TestRawODBCGuid()

static int TestRawODBCGuid ( void  )
static

◆ TestRawODBCPreparedQuery()

static int TestRawODBCPreparedQuery ( void  )
static

Variable Documentation

◆ _dbTests

DbTestEntry _dbTests[]
static
Initial value:
= {
{TestRawODBCDirectQuery, "Raw ODBC direct query"},
{TestRawODBCPreparedQuery, "Raw ODBC prepared query"},
{TestRawODBCGuid, "Raw ODBC GUID"},
{0, 0}
}
static int TestRawODBCGuid(void)
Definition: testodbc.c:182
static int TestRawODBCPreparedQuery(void)
Definition: testodbc.c:42
static int TestRawODBCDirectQuery(void)
Definition: testodbc.c:114

Array of tests.

Definition at line 381 of file testodbc.c.

◆ tests

DbTestEntry* tests = _dbTests
static
Modified on Mon Dec 11 02:36:42 2023 by modify_doxy.py rev. 669887