Skip to content

Commit

Permalink
tests: Add build test for GDB
Browse files Browse the repository at this point in the history
Adding a test to ensure that firecracker will build with the gdb flag
enabled

Signed-off-by: Jack Thomson <jackabt@amazon.com>
  • Loading branch information
JackThomson2 committed Oct 1, 2024
1 parent 2e090da commit 5497cdc
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions tests/integration_tests/build/test_gdb.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Copyright 2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0
"""A test that ensures that firecracker builds with GDB feature enabled at integration time."""

import platform

import pytest

import host_tools.cargo_build as host # pylint:disable=import-error

MACHINE = platform.machine()
TARGET = "{}-unknown-linux-musl".format(MACHINE)


@pytest.mark.skipif(MACHINE != "x86_64", reason="GDB runs only on x86_64.")
def test_gdb_compiles():
"""Checks that all benchmarks compile"""

host.cargo("build", f"--features gdb --target {TARGET}")

0 comments on commit 5497cdc

Please sign in to comment.