Home
last modified time | relevance | path

Searched +full:test +full:- +full:path (Results 1 – 25 of 340) sorted by relevance

12345678910>>...14

/qemu/tests/qtest/
H A Dqos-test.c21 #include "libqtest-single.h"
25 #include "qapi/qobject-input-visitor.h"
26 #include "qapi/qapi-visit-machine.h"
27 #include "qapi/qapi-visit-qom.h"
28 #include "libqos/libqos-malloc.h"
40 * This function firstly starts QEMU with "-machine none" option,
59 qtest_start("-machine none"); in qos_set_machines_devices_available()
60 response = qmp("{ 'execute': 'query-machines' }"); in qos_set_machines_devices_available()
74 response = qmp("{'execute': 'qom-list-types'," in qos_set_machines_devices_available()
89 static void restart_qemu_or_continue(char *path) in restart_qemu_or_continue() argument
[all …]
H A Dmax34451-test.c6 * SPDX-License-Identifier: GPL-2.0-or-later
11 #include "libqtest-single.h"
18 #define TEST_ID "max34451-test"
47 response = qmp("{ 'execute': 'qom-get', 'arguments': { 'path': %s, " in qmp_max34451_get()
61 response = qmp("{ 'execute': 'qom-set', 'arguments': { 'path': %s, " in qmp_max34451_set()
86 /* Test default values */
91 char *path; in test_defaults() local
95 path = g_strdup_printf("temperature[%d]", i); in test_defaults()
96 value = qmp_max34451_get(TEST_ID, path); in test_defaults()
98 g_free(path); in test_defaults()
[all …]
H A Dtpm-tis-test.c8 * Marc-André Lureau <marcandre.lureau@redhat.com>
12 * See the COPYING file in the top-level directory.
19 #include "io/channel-socket.h"
20 #include "libqtest-single.h"
22 #include "tpm-emu.h"
23 #include "tpm-tis-util.h"
30 char *args, *tmp_path = g_dir_make_tmp("qemu-tpm-tis-test.XXXXXX", NULL); in main()
32 TPMTestState test; in main() local
37 test.addr = g_new0(SocketAddress, 1); in main()
38 test.addr->type = SOCKET_ADDRESS_TYPE_UNIX; in main()
[all …]
H A Dtpm-tis-device-test.c8 * Marc-André Lureau <marcandre.lureau@redhat.com>
12 * See the COPYING file in the top-level directory.
18 #include "io/channel-socket.h"
19 #include "libqtest-single.h"
21 #include "tpm-emu.h"
22 #include "tpm-util.h"
23 #include "tpm-tis-util.h"
26 * As the Sysbus tpm-tis-device is instantiated on the ARM virt
34 char *tmp_path = g_dir_make_tmp("qemu-tpm-tis-device-test.XXXXXX", NULL); in main()
36 TPMTestState test; in main() local
[all …]
H A Dendianness-test.c10 * See the COPYING file in the top-level directory.
29 { "i386", "pc", -1 },
41 { "ppc64", "pseries-2.7", 0x10080000000ULL,
46 { "x86_64", "pc", -1 },
50 static uint8_t isa_inb(QTestState *qts, const TestCase *test, uint16_t addr) in isa_inb() argument
53 if (test->isa_base == -1) { in isa_inb()
56 value = qtest_readb(qts, test->isa_base + addr); in isa_inb()
61 static uint16_t isa_inw(QTestState *qts, const TestCase *test, uint16_t addr) in isa_inw() argument
64 if (test->isa_base == -1) { in isa_inw()
67 value = qtest_readw(qts, test->isa_base + addr); in isa_inw()
[all …]
H A Dcxl-test.c5 * See the COPYING file in the top-level directory.
9 #include "libqtest-single.h"
12 "-machine q35,cxl=on " \
13 "-device pxb-cxl,id=cxl.0,bus=pcie.0,bus_nr=52 " \
14 "-M cxl-fmw.0.targets.0=cxl.0,cxl-fmw.0.size=4G "
17 "-machine q35,cxl=on " \
18 "-device pxb-cxl,id=cxl.0,bus=pcie.0,bus_nr=52 " \
19 "-device pxb-cxl,id=cxl.1,bus=pcie.0,bus_nr=53 " \
20 "-M cxl-fmw.0.targets.0=cxl.0,cxl-fmw.0.targets.1=cxl.1,cxl-fmw.0.size=4G "
23 "-device cxl-rp,id=rp0,bus=cxl.0,chassis=0,slot=0 "
[all …]
/qemu/tests/functional/qemu_test/
H A Dcmd.py1 # Test class and utilities for functional tests
5 # Original Author (Avocado-based tests):
12 # later. See the COPYING file in the top-level directory.
16 import os.path
20 """ looks up the full path for @tool, returns None if not found
23 paths=os.getenv('PATH')
24 for p in paths.split(os.path.pathsep):
25 p = os.path.join(p, tool)
30 def is_readable_executable_file(path): argument
31 return os.path.isfile(path) and os.access(path, os.R_OK | os.X_OK)
[all …]
H A Dtestcase.py1 # Test class and utilities for functional tests
5 # Original Author (Avocado-based tests):
12 # later. See the COPYING file in the top-level directory.
16 from pathlib import Path
37 @params compressed: filename, Asset, or file-like object to uncompress
43 from the filename or Asset URL. @format must be non-None if @uncompressed
44 is a file-like object.
46 Returns the fully qualified path to the uncompressed file
53 (name, ext) = os.path.splitext(str(compressed))
54 uncompressed = self.scratch_file(os.path.basename(name))
[all …]
H A Dasset.py1 # Test utilities for fetching & caching assets
6 # later. See the COPYING file in the top-level directory.
16 from pathlib import Path
30 # starting with a name "ASSET_". This enables the pre-caching logic
40 self.cache_dir = Path(cache_dir_env, "download")
42 self.cache_dir = Path(Path("~").expanduser(),
44 self.cache_file = Path(self.cache_dir, hashsum)
45 self.log = logging.getLogger('qemu-test')
90 if os.path.exists(self.cache_file):
96 waittime -= 1
[all …]
/qemu/tests/qemu-iotests/
H A Dtestrunner.py3 # Copyright (c) 2020-2021 Virtuozzo International GmbH
20 from pathlib import Path
39 def silent_unlink(path: Path) -> None: argument
41 path.unlink()
46 def file_diff(file1: str, file2: str) -> List[str]:
47 with open(file1, encoding="utf-8") as f1, \
48 open(file2, encoding="utf-8") as f2:
61 """ Cache for elapsed time for tests, to show it during new test run
64 use it inside with-block or use save() after update().
66 def __init__(self, cache_file: str, env: TestEnv) -> None:
[all …]
H A Dcheck5 # Copyright (c) 2020-2021 Virtuozzo International GmbH
23 from pathlib import Path
31 Try to automagically figure out the path we are running from.
34 if os.path.islink(sys.argv[0]):
36 return os.path.dirname(os.readlink(sys.argv[0]))
38 return os.path.dirname(os.path.abspath(sys.argv[0]))
42 def make_argparser() -> argparse.ArgumentParser:
44 description="Test run options",
47 p.add_argument('-n', '--dry-run', action='store_true',
49 p.add_argument('-j', dest='jobs', type=int, default=1,
[all …]
/qemu/scripts/simplebench/
H A Dbench-backup.py3 # Bench backup block-job
31 cmd_options = env['cmd-options'] if 'cmd-options' in env else {}
32 return bench_block_copy(env['qemu-binary'], env['cmd'],
50 for t in args.test:
57 raise ValueError("'nbd' label used but --nbd is not given")
62 source = drv_qcow2(drv_file(dirs[src] + '/test-source.qcow2'))
64 source = drv_file(dirs[src] + '/test-source')
77 fname = dirs[dst] + '/test-target'
91 binaries = [] # list of (<label>, <path>, [<options>])
113 # path with colon inside is not supported
[all …]
H A Dbench_write_req.py3 # Test to compare performance of write requests for two qemu-img binary files.
5 # The idea of the test comes from intention to check the benefit of c8bb23cbdbe
40 '''Run qemu-img and return its output'''
47 sys.stderr.write('qemu-img received signal %i: %s\n'
48 % (-exitcode, ' '.join(list(args))))
56 The function creates a QCOW2 image with the given path/name. Then it runs
57 the 'qemu-img bench' command and makes series of write requests on the
61 qemu_img -- path to qemu_img executable file
62 image_name -- QCOW2 image name to create
63 block_size -- size of a block to write to clusters
[all …]
/qemu/tests/qtest/fuzz/
H A Dqos_fuzz.c2 * QOS-assisted fuzzing helpers
23 #include "qemu/main-loop.h"
26 #include "tests/qtest/libqos/libqos-malloc.h"
34 #include "qapi/qapi-commands-machine.h"
35 #include "qapi/qapi-commands-qom.h"
67 char **path = fuzz_path_vec; in qos_build_main_args() local
72 if (!path) { in qos_build_main_args()
73 fprintf(stderr, "QOS Path not found\n"); in qos_build_main_args()
77 /* Before test */ in qos_build_main_args()
78 cmd_line = g_string_new(path[0]); in qos_build_main_args()
[all …]
/qemu/tests/functional/
H A Dtest_acpi_bits.py23 # pylint: disable=invalid-name
24 # pylint: disable=consider-using-f-string
29 This test uses a fork of the upstream bits and has numerous fixes
31 https://gitlab.com/qemu-project/biosbits-bits .
49 # default timeout of 120 secs is sometimes not enough for bits test.
52 class QEMUBitsMachine(QEMUMachine): # pylint: disable=too-few-public-methods
54 A QEMU VM, with isa-debugcon enabled and bits iso passed
55 using -cdrom to QEMU commandline.
64 debugcon_log: str = "debugcon-log.txt",
67 # pylint: disable=too-many-arguments
[all …]
/qemu/tests/qemu-iotests/tests/
H A Dvvfat4 # Test vvfat driver implementation
29 filesystem = os.path.join(iotests.test_dir, "filesystem")
38 # pylint: disable=broad-exception-raised
39 def setUp(self) -> None:
40 if os.path.exists(filesystem):
41 if os.path.isdir(filesystem):
50 with open(os.path.join(filesystem, f"file{i}.txt"),
55 with open(os.path.join(filesystem, "large1.txt"), "wb") as f:
60 with open(os.path.join(filesystem, "large2.txt"), "wb") as f:
71 "node-name": "disk",
[all …]
/qemu/.gitlab-ci.d/
H A Dwindows.yml1 msys2-64bit:
4 - saas-windows-medium-amd64
8 - msys64/var/cache
9 - ccache
20 CONFIGURE_ARGS: --disable-system --enable-tools -Ddebug=false -Doptimization=0
22 GIT_FETCH_EXTRA_FLAGS: --no-tags --prune --quiet
24 name: "$CI_JOB_NAME-$CI_COMMIT_REF_SLUG"
27 - build/meson-logs/testlog.txt
29 junit: "build/meson-logs/testlog.junit.xml"
31 - Write-Output "Acquiring msys2.exe installer at $(Get-Date -Format u)"
[all …]
H A Dcrossbuild-template.yml7 - ccache
12 - source scripts/ci/gitlab-ci-section
13 - section_start setup "Pre-script setup"
14 - JOBS=$(expr $(nproc) + 1)
15 - cat /packages.txt
16 - section_end setup
18 - export CCACHE_BASEDIR="$(pwd)"
19 - export CCACHE_DIR="$CCACHE_BASEDIR/ccache"
20 - export CCACHE_MAXSIZE="500M"
21 - export PATH="$CCACHE_WRAPPERSDIR:$PATH"
[all …]
/qemu/tests/tcg/multiarch/system/
H A Dvalidate-memory-counts.py3 # validate-memory-counts.py: check we instrumented memory properly
6 # - the mem plugin output
7 # - the memory binary output
11 # SPDX-License-Identifier: GPL-2.0-or-later
16 def extract_counts(path): argument
18 Load the output from path and extract the lines containing:
20 Test data start: 0x40214000
21 Test data end: 0x40218001
22 Test data read: 2522280
23 Test data write: 262111
[all …]
H A DMakefile.softmmu-target1 # -*- Mode: makefile -*-
6 # architecture to add to the test dependencies and deal with the
18 GDB_SCRIPT=$(SRC_PATH)/tests/guest-debug/run-test.py
20 run-gdbstub-memory: memory
21 $(call run-test, $@, $(GDB_SCRIPT) \
22 --gdb $(GDB) \
23 --qemu $(QEMU) \
24 --output $<.gdb.out \
25 --qargs \
26 "-monitor none -display none -chardev file$(COMMA)path=$<.out$(COMMA)id=output $(QEMU_OPTS)" \
[all …]
/qemu/tests/image-fuzzer/
H A Drunner.py40 "'--config' and '--command' options are not supported.", file=sys.stderr)
96 return -term_signal
106 """Test object.
108 The class sets up test environment, generates backing and test images
109 and executes application under tests with specified arguments and a test
117 The test log will include application (e.g. 'qemu-img') logs besides info
123 """Set test environment in a specified work directory.
125 Path to qemu-img and qemu-io will be retrieved from 'QEMU_IMG' and
136 self.current_dir = os.path.join(work_dir, 'test-' + test_id)
138 os.environ.get('QEMU_IMG', 'qemu-img').strip().split(' ')
[all …]
/qemu/tests/qtest/migration/
H A Dmigration-util.c4 * Copyright (c) 2016-2018 Red Hat, Inc. and/or its affiliates
5 * based on the vhost-user-test.c that is:
9 * See the COPYING file in the top-level directory.
15 #include "qapi/qapi-visit-sockets.h"
16 #include "qapi/qobject-input-visitor.h"
23 #include "migration/migration-util.h"
36 /* For dirty ring test; so far only x86_64 is supported */
44 switch (addr->type) { in SocketAddress_to_str()
47 addr->u.inet.host, in SocketAddress_to_str()
48 addr->u.inet.port); in SocketAddress_to_str()
[all …]
/qemu/python/tests/
H A Dprotocol.py16 NullProtocol is a test mockup of an AsyncProtocol implementation.
18 It adds a fake_session instance variable that enables a code path
65 async def _do_recv(self) -> None:
69 def _do_send(self, msg: None) -> None:
72 async def send_msg(self) -> None:
75 async def simulate_disconnect(self) -> None:
77 Simulates a bottom-half disconnect.
88 returns bottom half errors as a pre-condition to allowing the
99 async def _do_recv(self) -> str:
105 def _do_send(self, msg: str) -> None:
[all …]
/qemu/tests/guest-debug/
H A Drun-test.py3 # Run a gdbstub test case
10 # See the COPYING file in the top-level directory.
12 # SPDX-License-Identifier: GPL-2.0-or-later
23 parser = argparse.ArgumentParser(description="A gdbstub test runner")
24 parser.add_argument("--qemu", help="Qemu binary for test",
26 parser.add_argument("--qargs", help="Qemu arguments for test")
27 parser.add_argument("--binary", help="Binary to debug",
29 parser.add_argument("--test", help="GDB test script")
31 help="Additional args for GDB test script. "
32 "The args should be preceded by -- to avoid confusion "
[all …]
/qemu/docs/devel/testing/
H A Dqgraph.rst6 In order to test a specific driver, plain libqos tests need to
8 This makes each test "hardcoded" for a specific configuration, reducing
12 therefore a generic sdhci test should test all machines and drivers that
14 Using only libqos APIs, the test has to manually take care of
22 a test aimed to a certain driver does not have to care of
29 so the sdhci-test should only care of linking its qgraph node with
34 ---------------
45 - **QNODE_MACHINE**: for example ``arm/raspi2b``
46 - **QNODE_DRIVER**: for example ``generic-sdhci``
47 - **QNODE_INTERFACE**: for example ``sdhci`` (interface for all ``-sdhci``
[all …]

12345678910>>...14