lintian doesn't like orphan packages with uploaders...
[debian/amanda] / common-src / match-test.c
index 8737e56584829f1f101625be1d8cee42eb365c14..eecf78c173f02c99382e9858e58be3a71e8e326a 100644 (file)
@@ -1,9 +1,10 @@
 /*
- * Copyright (c) 2010 Zmanda, Inc.  All Rights Reserved.
+ * Copyright (c) 2010-2012 Zmanda, Inc.  All Rights Reserved.
  *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 as published
- * by the Free Software Foundation.
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
  *
  * This program is distributed in the hope that it will be useful, but
  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
@@ -706,8 +707,10 @@ test_match_disk(void)
        { "\\\\\\\\windows\\\\share", "\\\\windows\\share", TRUE },
 
        /* other expressions */
-       { "^local", "/local", TRUE },
-       { "^local", "/local/vore", TRUE },
+       { "^local", "/local", FALSE },
+       { "^/local", "/local", TRUE },
+       { "^local", "/local/vore", FALSE },
+       { "^/local", "/local/vore", TRUE },
        { "^local", "/usr/local", FALSE },
 
        { "local/bin", "/local/bin", TRUE },
@@ -740,7 +743,41 @@ test_match_disk(void)
        { "/usr\\/bin", "/usr/bin", TRUE },
        { "^/usr\\/bin$", "/usr/bin", TRUE },
        { "\\/usr\\/bin", "/usr/bin", FALSE },
-       { "^\\/usr\\/bin$", "/usr/bin", FALSE },
+       { "^\\/usr\\/bin$", "/usr/bin", TRUE },
+       { "/usr\\/bin\\/", "/usr/bin/", TRUE },
+       { "^/usr\\/bin\\/$", "/usr/bin/", TRUE },
+       { "\\/usr\\/bin\\/", "/usr/bin/", FALSE },
+       { "^\\/usr\\/bin\\/$", "/usr/bin/", TRUE },
+
+       { "oracle", "oracle", TRUE },
+       { "oracle", "/oracle", TRUE },
+       { "oracle", "oracle/", TRUE },
+       { "oracle", "/oracle/", TRUE },
+       { "/oracle", "oracle", TRUE },
+       { "/oracle", "/oracle", TRUE },
+       { "/oracle", "oracle/", TRUE },
+       { "/oracle", "/oracle/", TRUE },
+       { "^oracle", "oracle", TRUE },
+       { "^oracle", "/oracle", FALSE },
+       { "^oracle", "oracle/", TRUE },
+       { "^oracle", "/oracle/", FALSE },
+       { "^/oracle", "oracle", FALSE },
+       { "^/oracle", "/oracle", TRUE },
+       { "^/oracle", "oracle/", FALSE },
+       { "^/oracle", "/oracle/", TRUE },
+
+       { "oracle", "oracle", TRUE },
+       { "oracle", "/oracle", TRUE },
+       { "oracle", "oracle/", TRUE },
+       { "oracle", "/oracle/", TRUE },
+       { "oracle$", "oracle", TRUE },
+       { "oracle$", "/oracle", TRUE },
+       { "oracle$", "oracle/", FALSE },
+       { "oracle$", "/oracle/", FALSE },
+       { "oracle/$", "oracle", FALSE },
+       { "oracle/$", "/oracle", FALSE },
+       { "oracle/$", "oracle/", TRUE },
+       { "oracle/$", "/oracle/", TRUE },
 
        { NULL, NULL, FALSE },
     }, *t;