Header And Logo

PostgreSQL
| The world's most advanced open source database.

isolationtester.h

Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------
00002  *
00003  * isolationtester.h
00004  *    include file for isolation tests
00005  *
00006  * Portions Copyright (c) 1996-2013, PostgreSQL Global Development Group
00007  * Portions Copyright (c) 1994, Regents of the University of California
00008  *
00009  * IDENTIFICATION
00010  *      src/test/isolation/isolationtester.h
00011  *
00012  *-------------------------------------------------------------------------
00013  */
00014 #ifndef ISOLATIONTESTER_H
00015 #define ISOLATIONTESTER_H
00016 
00017 typedef struct Session Session;
00018 typedef struct Step Step;
00019 
00020 struct Session
00021 {
00022     char       *name;
00023     char       *setupsql;
00024     char       *teardownsql;
00025     Step      **steps;
00026     int         nsteps;
00027 };
00028 
00029 struct Step
00030 {
00031     int         session;
00032     char       *name;
00033     char       *sql;
00034     char       *errormsg;
00035 };
00036 
00037 typedef struct
00038 {
00039     int         nsteps;
00040     char      **stepnames;
00041 }   Permutation;
00042 
00043 typedef struct
00044 {
00045     char      **setupsqls;
00046     int         nsetupsqls;
00047     char       *teardownsql;
00048     Session   **sessions;
00049     int         nsessions;
00050     Permutation **permutations;
00051     int         npermutations;
00052 }   TestSpec;
00053 
00054 extern TestSpec parseresult;
00055 
00056 extern int  spec_yyparse(void);
00057 
00058 extern int  spec_yylex(void);
00059 extern void spec_yyerror(const char *str);
00060 
00061 #endif   /* ISOLATIONTESTER_H */