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-21 11:41:10 +01:00
Code Issues Packages Projects Releases Wiki Activity
Files
f686f1dc17958e7cd36edd24bb991fcdabb94f3e
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: 57ms Template: 2ms
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