mirror of
https://github.com/systemd/systemd.git
synced 2024-12-23 21:35:11 +03:00
[PATCH] udev add some ID tests
Patch against current udev bk to add a few ID rule tests.
This commit is contained in:
parent
ab2e5bd946
commit
93656247f3
@ -384,6 +384,52 @@ EOF
|
||||
expected => "rd/c0d0" ,
|
||||
conf => <<EOF
|
||||
KERNEL="ttyUSB0", NAME="visor"
|
||||
EOF
|
||||
},
|
||||
{
|
||||
desc => "ID rule",
|
||||
subsys => "block",
|
||||
devpath => "block/sda",
|
||||
expected => "scsi-0:0:0:0",
|
||||
conf => <<EOF
|
||||
BUS="usb", ID="0:0:0:0", NAME="not-scsi"
|
||||
BUS="scsi", ID="0:0:0:1", NAME="no-match"
|
||||
BUS="scsi", ID=":0", NAME="short-id"
|
||||
BUS="scsi", ID="/0:0:0:0", NAME="no-match"
|
||||
BUS="scsi", ID="0:0:0:0", NAME="scsi-0:0:0:0"
|
||||
EOF
|
||||
},
|
||||
{
|
||||
desc => "ID wildcard all",
|
||||
subsys => "block",
|
||||
devpath => "block/sda",
|
||||
expected => "scsi-0:0:0:0",
|
||||
conf => <<EOF
|
||||
BUS="scsi", ID="*:1", NAME="no-match"
|
||||
BUS="scsi", ID="*:0:1", NAME="no-match"
|
||||
BUS="scsi", ID="*:0:0:1", NAME="no-match"
|
||||
BUS="scsi", ID="*", NAME="scsi-0:0:0:0"
|
||||
BUS="scsi", ID="0:0:0:0", NAME="bad"
|
||||
EOF
|
||||
},
|
||||
{
|
||||
desc => "ID wildcard partial",
|
||||
subsys => "block",
|
||||
devpath => "block/sda",
|
||||
expected => "scsi-0:0:0:0",
|
||||
conf => <<EOF
|
||||
BUS="scsi", ID="*:0", NAME="scsi-0:0:0:0"
|
||||
BUS="scsi", ID="0:0:0:0", NAME="bad"
|
||||
EOF
|
||||
},
|
||||
{
|
||||
desc => "ID wildcard partial 2",
|
||||
subsys => "block",
|
||||
devpath => "block/sda",
|
||||
expected => "scsi-0:0:0:0",
|
||||
conf => <<EOF
|
||||
BUS="scsi", ID="*:0:0:0", NAME="scsi-0:0:0:0"
|
||||
BUS="scsi", ID="0:0:0:0", NAME="bad"
|
||||
EOF
|
||||
},
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user