virttest: Update the method to get test case name in write_subtests_file...

...s

We have some subtest name include "-". And the original method will use
the last word in the test case name as the whole case name in the subtest.cfg.
We have a case named "sr-iov". And if we split it we should join the string later. So as we know the name will include "-" at the beginning. So just remove it should be acceptable.