tests: udev - assume /etc/machine-id rather than /etc/hosts

On todays machines /etc/hosts is not mandatory. /etc/machine-id is though, so let's rely on that instead.

This makes the udev tests pass again for me.
This commit is contained in:
Tom Gundersen
2014-12-11 14:17:35 +01:00
parent 8b516fdea7
commit 02cd084db7

View File

@@ -1233,8 +1233,8 @@ EOF
devpath => "/devices/pci0000:00/0000:00:1f.2/host0/target0:0:0/0:0:0:0/block/sda",
exp_name => "there",
rules => <<EOF
TEST=="/etc/hosts", SYMLINK+="there"
TEST!="/etc/hosts", SYMLINK+="notthere"
TEST=="/etc/machine-id", SYMLINK+="there"
TEST!="/etc/machine-id", SYMLINK+="notthere"
EOF
},
{