chiark / gitweb /
[PATCH] add a script that tests the IGNORE rule
[elogind.git] / test / udev-test.pl
index ea1d8611efa6f377966c87d30dd7657d62e9d11e..97c009492124005ae641c5c38fe4bf56b4df56f1 100644 (file)
@@ -215,13 +215,43 @@ CALLOUT, BUS="scsi", PROGRAM="/bin/echo -n node link1 link2", ID="node *", NAME=
 EOF
        },
        {
-               desc     => "callout for device with no bus",
+               desc     => "invalid callout for device with no bus",
                subsys   => "tty",
                devpath  => "class/tty/console",
                expected => "TTY" ,
                conf     => <<EOF
 CALLOUT, BUS="scsi", PROGRAM="/bin/echo -n foo", ID="foo", NAME="foo"
 REPLACE, KERNEL="console", NAME="TTY"
+EOF
+       },
+       {
+               desc     => "valid callout for device with no bus",
+               subsys   => "tty",
+               devpath  => "class/tty/console",
+               expected => "foo" ,
+               conf     => <<EOF
+CALLOUT, PROGRAM="/bin/echo -n foo", ID="foo", NAME="foo"
+REPLACE, KERNEL="console", NAME="TTY"
+EOF
+       },
+       {
+               desc     => "invalid label for device with no bus",
+               subsys   => "tty",
+               devpath  => "class/tty/console",
+               expected => "TTY" ,
+               conf     => <<EOF
+LABEL, BUS="foo", SYSFS_dev="5:1", NAME="foo"
+REPLACE, KERNEL="console", NAME="TTY"
+EOF
+       },
+       {
+               desc     => "valid label for device with no bus",
+               subsys   => "tty",
+               devpath  => "class/tty/console",
+               expected => "foo" ,
+               conf     => <<EOF
+LABEL, SYSFS_dev="5:1", NAME="foo"
+REPLACE, KERNEL="console", NAME="TTY"
 EOF
        },
        {