]> sjero.net Git - wget/blobdiff - src/test.c
mass change: update copyright years.
[wget] / src / test.c
index 3187900db44c5da3c3f01746dcf69adb012b4434..e7ce54cf74340dd3384a5844435476e69b4b0862 100644 (file)
@@ -1,5 +1,6 @@
 /* Unit testing.
-   Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+   Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
+   Foundation, Inc.
 
 This file is part of GNU Wget.
 
@@ -59,27 +60,32 @@ all_tests()
   mu_run_test (test_append_uri_pathel);
   mu_run_test (test_are_urls_equal);
   mu_run_test (test_is_robots_txt_url);
-  
+
   return NULL;
 }
 
+char *program_name; /* Needed by lib/error.c. */
 
 int
-main (void) 
+main (int argc, char *argv[])
 {
-  const char *result = all_tests();
-  
-  if (result != NULL) 
+  const char *result;
+
+  program_name = argv[0];
+
+  result = all_tests();
+
+  if (result != NULL)
     {
       puts (result);
     }
-  else 
+  else
     {
       printf ("ALL TESTS PASSED\n");
     }
-  
+
   printf ("Tests run: %d\n", tests_run);
+
   return result != 0;
 }