Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KVM: Update x86_cpuid and feature_test test case #411

Merged
merged 2 commits into from
Oct 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion KVM/qemu/tests/feature_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def get_test_results(test, output, vm, session):
:param session: Guest session
"""
remove_str = "job.log"
guest_log = re.sub(remove_str, "", output.splitlines()[1].split(":")[1].strip())
guest_log = re.sub(remove_str, "", re.search(r'.*JOB LOG\s*:\s(.*)', output).group(1))
# Delete the symbolic link to avoid remote copy failure
session.cmd("rm %s/test-results/by-status -rf" % guest_log, ignore_all_errors=True)

Expand Down
4 changes: 2 additions & 2 deletions KVM/qemu/tests/x86_cpuid.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
curr_dir = os.path.dirname(os.path.abspath(__file__))
check_dir = "%s/../../../BM/instruction-check" % curr_dir
sys.path.append(check_dir)
from feature_list import cpuid_info
from feature_list import feature_list


def prepare_cpuid(test, params, src_dir, vm=None, session=None):
Expand Down Expand Up @@ -62,7 +62,7 @@ def check_cpuid(params, feature, exec_bin, session=None):
:param exec_bin: The execuable bianry tool with absolute path
:param session: Guest session
"""
args = cpuid_info[feature]
args = feature_list[feature]["cpuid"]
args_str = ' '.join(args)

check_cmd = '%s %s' % (exec_bin, args_str)
Expand Down
Loading