mirror of
https://github.com/espressif/esp-idf.git
synced 2026-04-27 19:13:21 +00:00
test(cmakev2): Assert ELF output in Linux target build test
Made-with: Cursor
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
import logging
|
||||
import sys
|
||||
from pathlib import Path
|
||||
|
||||
import pytest
|
||||
from test_build_system_helpers import IdfPyFunc
|
||||
@@ -12,3 +13,6 @@ from test_build_system_helpers import IdfPyFunc
|
||||
def test_linux_target_build(idf_py: IdfPyFunc) -> None:
|
||||
logging.info('Can build for Linux target')
|
||||
idf_py('--preview', '-DIDF_TARGET=linux', 'build')
|
||||
elf = Path('build/build_test_app.elf')
|
||||
assert elf.exists(), 'ELF file was not produced by the Linux build'
|
||||
assert elf.stat().st_size > 0, 'ELF file is empty — link step may have failed silently'
|
||||
|
||||
Reference in New Issue
Block a user