qemu.tests: Use qemu-kvm -M ? to get machine type for physical resource ...

...check

The old method to get expect machine type can not fit machine type check for
q35 and pc. So update it by get the machine type string from the output
of qemu-kvm -M ?.