virttest.utils_test: Add two functions for cdrom attach and eject

Signed-off-by: Yanbing Du <ydu@redhat.com>