Commit de9f15e8 authored by Barry Perlman's avatar Barry Perlman Committed by Yoni Fogel

Added test for checkpoint callback.


git-svn-id: file:///svn/toku/tokudb@11315 c7de825b-a66e-492c-adef-691d508d4ae1
parent 86f17068
......@@ -2,6 +2,7 @@
#ident "Copyright (c) 2007 Tokutek Inc. All rights reserved."
#ident "$Id$"
#include "test.h"
#include <db.h>
#include <sys/stat.h>
DB_ENV *env;
......@@ -284,6 +285,14 @@ runtests(u_int32_t flags, u_int32_t n, int snap_all) {
checkpoint_test_1(flags, n, snap_all);
}
void checkpoint_callback(void * UU(extra)) {
if (verbose) {
printf("checkpoint callback called\n");
fflush(stdout);
}
}
int
test_main (int argc, const char *argv[]) {
parse_args(argc, argv);
......@@ -301,6 +310,10 @@ test_main (int argc, const char *argv[]) {
runtests(DB_DUP|DB_DUPSORT, n, snap);
}
}
db_env_set_checkpoint_callback(checkpoint_callback, NULL);
runtests(0,4,1);
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment