4 * Expected SUCCESSes for all tests: FIX [+ FIX ...]
5 * (List number of lines containing the
6 * string "SUCCESS" that are expected
7 * to be printed to stdout.)
12 * FIX Short test description/table of contents. SUCCESSes: FIX
15 #include <net-snmp/net-snmp-config.h>
17 #include <sys/types.h>
28 extern int optind, optopt, opterr;
37 #define USAGE "Usage: %s [-h][-aS]"
38 #define OPTIONLIST "ahS"
40 int doalltests = 0, dosomething = 0;
42 #define ALLOPTIONS (doalltests + dosomething)
46 #define LOCAL_MAXBUF (1024 * 8)
49 #define OUTPUT(o) fprintf(stdout, "\n\n%s\n\n", o);
54 fprintf(stdout, "\nSUCCESS: %s\n", s); \
57 #define FAILED(e, f) \
59 if (e != SNMPERR_SUCCESS) { \
60 fprintf(stdout, "\nFAILED: %s\n", f); \
72 void usage(FILE * ofp);
74 int test_dosomething(void);
80 main(int argc, char **argv)
82 int rval = SNMPERR_SUCCESS, failcount = 0;
85 local_progname = argv[0];
92 while ((ch = getopt(argc, argv, OPTIONLIST)) != EOF) {
115 } /* endwhile getopt */
121 } else if (ALLOPTIONS != 1) {
130 if (dosomething || doalltests) {
131 failcount += test_dosomething();
153 " -S Test something." NL
154 " -h Help." NL "" NL, local_progname);
163 /*******************************************************************-o-******
167 * Number of failures.
173 test_dosomething(void)
175 int rval = SNMPERR_SUCCESS, failcount = 0;
177 EM0(1, "UNIMPLEMENTED"); /* EM(1); /* */
179 test_dosomething_quit:
182 } /* end test_dosomething() */