Logo
Explore Help
Register Sign In
TeamHepta/mbedtls
1
0
Fork 0
You've already forked mbedtls
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2026-03-24 21:21:10 +01:00
Code Issues Packages Projects Releases Wiki Activity
Files
0eb4e7fb40cd8ff851ef32b82f353f3f21e308e5
mbedtls/tests/scripts/scripts_path.py

18 lines
412 B
Python
Raw Normal View History

Allow tests/scripts/foo.py to import from scripts Allow Python scripts in tests/scripts to import modules located in the scripts directory. To do this, use ``` import scripts_path # pylint: disable=unused-import ``` Declare the scripts directory to pylint and to mypy. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2020-12-10 23:11:59 +01:00
"""Add our Python library directory to the module search path.
Usage:
import scripts_path # pylint: disable=unused-import
"""
# Copyright The Mbed TLS Contributors
update headers Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-02 19:47:20 +00:00
# SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
Allow tests/scripts/foo.py to import from scripts Allow Python scripts in tests/scripts to import modules located in the scripts directory. To do this, use ``` import scripts_path # pylint: disable=unused-import ``` Declare the scripts directory to pylint and to mypy. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2020-12-10 23:11:59 +01:00
#
import os
import sys
sys.path.append(os.path.join(os.path.dirname(__file__),
os.path.pardir, os.path.pardir,
'scripts'))
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.25.3 Page: 151ms Template: 8ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API