zephyr/scripts/west_commands/tests/conftest.py
Gerson Fernando Budke c3db83ba58 scripts: runners: openocd: Enable thread awareness
Zephyr thread awareness is available for openocd but boards don't
have debuggers configuration.  This configure OpenOCD runner
automatically to complete configuration.

User still require enable CONFIG_DEBUG_THREAD_INFO=y to visualize
thread debug information.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2021-08-27 06:44:45 -04:00

27 lines
791 B
Python

# Copyright (c) 2018 Foundries.io
#
# SPDX-License-Identifier: Apache-2.0
'''Common fixtures for use testing the runner package.'''
import pytest
from runners.core import RunnerConfig
RC_BUILD_DIR = '/test/build-dir'
RC_BOARD_DIR = '/test/zephyr/boards/test-arch/test-board'
RC_KERNEL_ELF = 'test-zephyr.elf'
RC_KERNEL_HEX = 'test-zephyr.hex'
RC_KERNEL_BIN = 'test-zephyr.bin'
RC_GDB = 'test-none-gdb'
RC_OPENOCD = 'test-openocd'
RC_OPENOCD_SEARCH = ['/test/openocd/search']
@pytest.fixture
def runner_config():
'''Fixture which provides a runners.core.RunnerConfig.'''
return RunnerConfig(RC_BUILD_DIR, RC_BOARD_DIR, RC_KERNEL_ELF,
RC_KERNEL_HEX, RC_KERNEL_BIN, gdb=RC_GDB,
openocd=RC_OPENOCD, openocd_search=RC_OPENOCD_SEARCH)