[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts tha
From: |
John Snow |
Subject: |
Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits |
Date: |
Mon, 11 Jul 2022 16:38:46 -0400 |
On Sun, Jul 10, 2022 at 1:01 PM Ani Sinha <ani@anisinha.ca> wrote:
>
> This is initial commit of cpuid, acpi and smbios python test scripts for
> biosbits to execute. No change has been made to them from the original code
> written by the biosbits author Josh Triplett. They are required to be
> installed
> into the bits iso file and then run from within the virtual machine booted off
> with biosbits iso.
>
> The original location of these tests are here:
> https://github.com/biosbits/bits/blob/master/python/testacpi.py
> https://github.com/biosbits/bits/blob/master/python/smbios.py
> https://github.com/biosbits/bits/blob/master/python/testcpuid.py
>
> Signed-off-by: Ani Sinha <ani@anisinha.ca>
> ---
> tests/pytest/acpi-bits/bits-tests/meson.build | 11 +
> tests/pytest/acpi-bits/bits-tests/smbios.py | 2430 +++++++++++++++++
> tests/pytest/acpi-bits/bits-tests/testacpi.py | 283 ++
> .../pytest/acpi-bits/bits-tests/testcpuid.py | 83 +
> 4 files changed, 2807 insertions(+)
> create mode 100644 tests/pytest/acpi-bits/bits-tests/meson.build
> create mode 100644 tests/pytest/acpi-bits/bits-tests/smbios.py
> create mode 100644 tests/pytest/acpi-bits/bits-tests/testacpi.py
> create mode 100644 tests/pytest/acpi-bits/bits-tests/testcpuid.py
>
> diff --git a/tests/pytest/acpi-bits/bits-tests/meson.build
> b/tests/pytest/acpi-bits/bits-tests/meson.build
> new file mode 100644
> index 0000000000..3056731a53
> --- /dev/null
> +++ b/tests/pytest/acpi-bits/bits-tests/meson.build
> @@ -0,0 +1,11 @@
> +test_files = ['smbios.py', 'testacpi.py', 'testcpuid.py']
> +
> +copytestfiles = custom_target('copy test files',
> + input : test_files,
> + output : test_files,
> + command : ['cp', '@INPUT@', '@OUTDIR@'],
> + install : true,
> + install_dir : 'bits-tests',
> + build_by_default : true)
> +
> +other_deps += copytestfiles
> diff --git a/tests/pytest/acpi-bits/bits-tests/smbios.py
> b/tests/pytest/acpi-bits/bits-tests/smbios.py
> new file mode 100644
> index 0000000000..9667d0542c
> --- /dev/null
> +++ b/tests/pytest/acpi-bits/bits-tests/smbios.py
> @@ -0,0 +1,2430 @@
> +# Copyright (c) 2015, Intel Corporation
> +# All rights reserved.
> +#
> +# Redistribution and use in source and binary forms, with or without
> +# modification, are permitted provided that the following conditions are met:
> +#
> +# * Redistributions of source code must retain the above copyright
> notice,
> +# this list of conditions and the following disclaimer.
> +# * Redistributions in binary form must reproduce the above copyright
> notice,
> +# this list of conditions and the following disclaimer in the
> documentation
> +# and/or other materials provided with the distribution.
> +# * Neither the name of Intel Corporation nor the names of its
> contributors
> +# may be used to endorse or promote products derived from this software
> +# without specific prior written permission.
> +#
> +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
> IS" AND
> +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
> IMPLIED
> +# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
> +# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
> LIABLE FOR
> +# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
> DAMAGES
> +# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
> SERVICES;
> +# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
> AND ON
> +# ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
> +# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
> THIS
> +# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
> +
> +"""SMBIOS/DMI module."""
> +
> +import bits
> +import bitfields
New deps?
> +import ctypes
> +import redirect
Also a new dep?
> +import struct
> +import uuid
> +import unpack
And another?
> +import ttypager
> +import sys
What's the proposed strategy for dependency management for these
tests? I know there's some mail I'm backlogged on ...
- [PATCH v2 00/11] Introduce new acpi/smbios python tests using biosbits, Ani Sinha, 2022/07/10
- [PATCH v2 02/11] acpi/tests/bits: add SPDX license identifiers for bios bits tests, Ani Sinha, 2022/07/10
- [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits, Ani Sinha, 2022/07/10
- Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits,
John Snow <=
- Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits, Ani Sinha, 2022/07/12
- Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits, John Snow, 2022/07/12
- Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits, Ani Sinha, 2022/07/12
- Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits, John Snow, 2022/07/12
- Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits, Ani Sinha, 2022/07/12
[PATCH v2 03/11] acpi/tests/bits: disable acpi PSS tests that are failing in biosbits, Ani Sinha, 2022/07/10
[PATCH v2 04/11] acpi/tests/bits: add smilatency test suite from bits in order to disable it, Ani Sinha, 2022/07/10
[PATCH v2 05/11] acpi/tests/bits: add SPDX license identifiers for bios bits smilatency tests, Ani Sinha, 2022/07/10
[PATCH v2 06/11] acpi/tests/bits: disable smilatency test since it does not pass everytime, Ani Sinha, 2022/07/10
[PATCH v2 07/11] acpi/tests/bits: add python test that exercizes QEMU bios tables using biosbits, Ani Sinha, 2022/07/10