2 * Copyright (C) 2009 Red Hat Inc.
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License along
15 * with this program; if not, write to the Free Software Foundation, Inc.,
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
19 /* This program, which must be statically linked, is used to test the
20 * guestfs_command and guestfs_command_lines functions.
30 #include "../src/guestfs-internal.h"
33 main (int argc, char *argv[])
36 if (STREQ (argv[1], "1")) {
38 } else if (STREQ (argv[1], "2")) {
40 } else if (STREQ (argv[1], "3")) {
42 } else if (STREQ (argv[1], "4")) {
43 printf ("\nResult4\n");
44 } else if (STREQ (argv[1], "5")) {
45 printf ("\nResult5\n\n");
46 } else if (STREQ (argv[1], "6")) {
47 printf ("\n\nResult6\n\n");
48 } else if (STREQ (argv[1], "7")) {
50 } else if (STREQ (argv[1], "8")) {
52 } else if (STREQ (argv[1], "9")) {
54 } else if (STREQ (argv[1], "10")) {
55 printf ("Result10-1\nResult10-2\n");
56 } else if (STREQ (argv[1], "11")) {
57 printf ("Result11-1\nResult11-2");
59 fprintf (stderr, "unknown parameter: %s\n", argv[1]);
63 fprintf (stderr, "missing parameter\n");