Re: [kvm-unit-tests PATCH] Add a .gitlab-ci.yml file for automatic CI testing on GitLab instances

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Mar 01, 2019 at 07:39:15AM +0100, Thomas Huth wrote:
> When changing common code of the kvm-unit-tests, one should make sure that
> the tests still compile fine for all target architectures afterwards. But
> compiling kvm-unit-tests for all target architectures manually is cumbersome.
> For people like me who store their git trees on GitLab, this can be done
> automatically via a CI system instead. Using the .gitlab-ci.yml file, auto-
> matic builds are now triggered on each push to a kvm-unit-test repository on
> gitlab.com. Additionally, the script also runs the tests that can be executed
> with QEMU TCG (except for s390x, since the QEMU package of the CI container
> currently does not provide the required s390-ccw bios here).
> 
> Signed-off-by: Thomas Huth <thuth@xxxxxxxxxx>
> ---
>  An example output can be found here:
>  https://gitlab.com/huth/kvm-unit-tests/pipelines/49788391
> 
>  .gitlab-ci.yml | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 78 insertions(+)
>  create mode 100644 .gitlab-ci.yml
> 
> diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
> new file mode 100644
> index 0000000..bc6ca0e
> --- /dev/null
> +++ b/.gitlab-ci.yml
> @@ -0,0 +1,78 @@
> +before_script:
> + - apt-get update -qq
> + - apt-get install -y -qq qemu-system
> +
> +build-aarch64:
> + script:
> + - apt-get install -y -qq gcc-aarch64-linux-gnu
> + - ./configure --arch=aarch64 --processor=arm64

If we're explicitly selecting the processor, then we should use the one
that configure will fix it up to.

 --processor=cortex-a57

> +     --cross-prefix=aarch64-linux-gnu-
> + - make -j2
> + - ACCEL=tcg ./run_tests.sh
> +     selftest-setup selftest-vectors-kernel selftest-vectors-user selftest-smp
> +     pci-test gicv2-active gicv3-active timer

Any reason to just pick the 'active' tests from the gic tests? And to drop
PMU and PSCI tests?

> +     | tee results.txt
> + - if grep -q FAIL results.txt ; then exit 1 ; fi
> +
> +build-arm:
> + script:
> + - apt-get install -y -qq gcc-arm-linux-gnueabi
> + - ./configure --arch=arm --processor=arm --cross-prefix=arm-linux-gnueabi-

Same for arm.

 --processor=cortex-a15

Thanks,
drew

> + - make -j2
> + - ACCEL=tcg ./run_tests.sh
> +     selftest-setup selftest-vectors-kernel selftest-vectors-user selftest-smp
> +     pci-test gicv2-active gicv3-active
> +     | tee results.txt
> + - if grep -q FAIL results.txt ; then exit 1 ; fi
> +
> +build-ppc64be:
> + script:
> + - apt-get install -y -qq gcc-powerpc64-linux-gnu
> + - ./configure --arch=ppc64 --processor=powerpc --endian=big
> +     --cross-prefix=powerpc64-linux-gnu-
> + - make -j2
> + - ACCEL=tcg ./run_tests.sh
> +     selftest-setup spapr_hcall rtas-get-time-of-day rtas-get-time-of-day-base
> +     rtas-set-time-of-day emulator
> +     | tee results.txt
> + - if grep -q FAIL results.txt ; then exit 1 ; fi
> +
> +build-ppc64le:
> + script:
> + - apt-get install -y -qq gcc-powerpc64-linux-gnu
> + - ./configure --arch=ppc64 --processor=powerpc --endian=little
> +     --cross-prefix=powerpc64-linux-gnu-
> + - make -j2
> + - ACCEL=tcg ./run_tests.sh
> +     selftest-setup spapr_hcall rtas-get-time-of-day rtas-get-time-of-day-base
> +     rtas-set-time-of-day emulator
> +     | tee results.txt
> + - if grep -q FAIL results.txt ; then exit 1 ; fi
> +
> +build-s390x:
> + script:
> + - apt-get install -y -qq gcc-s390x-linux-gnu
> + - ./configure --arch=s390x --processor=s390x --cross-prefix=s390x-linux-gnu-
> + - make -j2
> +
> +build-x86_64:
> + script:
> + - ./configure --arch=x86_64 --processor=x86_64
> + - make -j2
> + - ACCEL=tcg ./run_tests.sh
> +     ioapic-split ioapic smptest smptest3 vmexit_cpuid vmexit_mov_from_cr8
> +     vmexit_mov_to_cr8 vmexit_inl_pmtimer  vmexit_ipi vmexit_ipi_halt
> +     vmexit_ple_round_robin vmexit_tscdeadline vmexit_tscdeadline_immed
> +     eventinj msr port80 sieve tsc rmap_chain umip hyperv_stimer intel_iommu
> +     | tee results.txt
> + - if grep -q FAIL results.txt ; then exit 1 ; fi
> +
> +build-i386:
> + script:
> + - apt-get install -y -qq gcc-multilib
> + - ./configure --arch=i386 --processor=i386
> + - make -j2
> + - ACCEL=tcg ./run_tests.sh
> +     eventinj port80 sieve tsc taskswitch umip hyperv_stimer
> +     | tee results.txt
> + - if grep -q FAIL results.txt ; then exit 1 ; fi
> -- 
> 1.8.3.1
> 



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux