File tree Expand file tree Collapse file tree 2 files changed +13
-10
lines changed
tests/integration_tests/functional
tools/create_snapshot_artifact Expand file tree Collapse file tree 2 files changed +13
-10
lines changed Original file line number Diff line number Diff line change 5
5
6
6
import json
7
7
import logging
8
+ import platform
8
9
from pathlib import Path
9
10
10
11
import pytest
16
17
guest_run_fio_iteration ,
17
18
populate_data_store ,
18
19
)
19
- from framework .utils_cpuid import CpuVendor , get_cpu_vendor
20
+ from framework .utils_cpu_templates import get_supported_cpu_templates
20
21
from framework .utils_vsock import check_vsock_device
21
22
from integration_tests .functional .test_balloon import (
22
23
get_stable_rss_mem_by_pid ,
@@ -74,9 +75,10 @@ def get_snapshot_dirs():
74
75
"""Get all the snapshot directories"""
75
76
snapshot_root_name = "snapshot_artifacts"
76
77
snapshot_root_dir = Path (FC_WORKSPACE_DIR ) / snapshot_root_name
77
- cpu_templates = ["C3" , "T2" , "T2S" , "None" ]
78
- if get_cpu_vendor () != CpuVendor . INTEL :
78
+ cpu_templates = []
79
+ if platform . machine () == "x86_64" :
79
80
cpu_templates = ["None" ]
81
+ cpu_templates += get_supported_cpu_templates ()
80
82
for cpu_template in cpu_templates :
81
83
for snapshot_dir in snapshot_root_dir .glob (f"*_{ cpu_template } _guest_snapshot" ):
82
84
assert snapshot_dir .is_dir ()
Original file line number Diff line number Diff line change 5
5
6
6
import json
7
7
import os
8
+ import platform
8
9
import re
9
10
import shutil
10
11
import sys
21
22
generate_mmds_get_request ,
22
23
generate_mmds_session_token ,
23
24
)
24
- from framework .utils_cpuid import CpuVendor , get_cpu_vendor
25
+ from framework .utils_cpu_templates import get_supported_cpu_templates
25
26
from host_tools .cargo_build import get_firecracker_binaries
26
27
27
-
28
28
# pylint: enable=wrong-import-position
29
29
30
30
# Default IPv4 address to route MMDS requests.
@@ -78,8 +78,8 @@ def main():
78
78
|
79
79
-> vm.mem
80
80
-> vm.vmstate
81
- -> ubuntu-18 .04.id_rsa
82
- -> ubuntu-18 .04.ext4
81
+ -> ubuntu-22 .04.id_rsa
82
+ -> ubuntu-22 .04.ext4
83
83
-> <guest_kernel_supported_1>_<cpu_template>_guest_snapshot
84
84
|
85
85
...
@@ -90,9 +90,10 @@ def main():
90
90
shutil .rmtree (SNAPSHOT_ARTIFACTS_ROOT_DIR , ignore_errors = True )
91
91
vm_factory = MicroVMFactory (* get_firecracker_binaries ())
92
92
93
- cpu_templates = ["None" ]
94
- if get_cpu_vendor () == CpuVendor .INTEL :
95
- cpu_templates .extend (["C3" , "T2" , "T2S" ])
93
+ cpu_templates = []
94
+ if platform .machine () == "x86_64" :
95
+ cpu_templates = ["None" ]
96
+ cpu_templates += get_supported_cpu_templates ()
96
97
97
98
for cpu_template in cpu_templates :
98
99
for kernel in kernels (glob = "vmlinux-*" ):
You can’t perform that action at this time.
0 commit comments