Ron Eldor
9d40da275d
Make the script portable to both pythons
...
Make the script work for python3 and for python2
2019-07-11 14:36:20 +03:00
Ron Eldor
b43fe57d34
Update the test encoding to support python3
...
Since Python3 handles encoding differently than Python2,
a change in the way the data is encoded and sent to the target is needed.
1. Change the test data to be sent as hex string
2. Convert the characters to binary bytes.
This is done because the mbed tools translate the encoding differently
(mbed-greentea, and mbed-htrunner)
2019-07-11 14:36:13 +03:00
Ron Eldor
56b6e523fa
update the test script
...
Update `mbedtls_test.py` script to work with Python 3.7.
resolves #2653
2019-07-11 14:36:06 +03:00
Gilles Peskine
afd19dd9b6
Silence pylint
...
Silence pylint in specific places where we're doing slightly unusual
or dodgy, but correct.
2019-02-25 21:42:32 +01:00
Jaeden Amero
5677eab235
Merge remote-tracking branch 'origin/pr/2207' into mbedtls-2.16
2019-01-30 14:57:30 +00:00
Jaeden Amero
484d883a1d
Merge remote-tracking branch 'origin/pr/2191' into mbedtls-2.16
2019-01-30 14:56:38 +00:00
Ron Eldor
111ba0e949
Fix parsing error of test data
...
Fix parsing error that contains special character.
The previous implementation replaced the `:` char with `\n`,
and split on `\n`. Test data containing strings with `\n`
were split as well. Fixes #2193 .
The split function caused strings containing `\:` to add
another escape char, resulting in `\\:`. This caused the
tests with the `\:` in the string data to fail.
The fix doesn't replace with `\n`, but splits all `:` that
are not preceded with `\`. After that, removes the preceding `\` char.
2018-11-27 13:48:13 +02:00
Ron Eldor
8672cb7909
Set result to False on Failure
...
Add a member for holding a failed result,
and notify_complete with this member value, when finished.
2018-11-21 14:02:12 +02:00
Ron Eldor
c242eea732
Change data file suffix for ott
...
Change the suffix of the data files searched in `mbedtls_test.py`
to `datax` as the generated files have this suffix.
2018-11-05 16:22:36 +02:00
Mohammad Azim Khan
32cbcdac8f
Fix Pylint errors in Python scripts
2018-08-06 11:42:56 +01:00
Azim Khan
630281349e
Replaced escaped_split() logic with regex
2018-08-06 11:42:56 +01:00
Azim Khan
8d686bfdb1
Incorporated code revoew comments.
2018-08-06 11:42:56 +01:00
Azim Khan
b31aa44e16
Fix style errors reported by pylint
2018-08-06 11:42:56 +01:00
Azim Khan
951a2c8898
Improve documentation in mbedtls_test.py
2018-08-06 11:42:06 +01:00
Azim Khan
b98e6eec58
Replace asserts with exceptions in mbedtls_test.py
2018-08-06 11:42:06 +01:00
Mohammad Azim Khan
9b06f37601
Give execute permissions to Python scripts
2018-08-06 11:40:58 +01:00
Mohammad Azim Khan
78befd9019
Rename generate_code.py -> generate_test_code.py
2018-08-06 11:40:58 +01:00
Azim Khan
f0e42fbd1f
Add missing documentation and fix file doc strings
2018-08-06 11:40:58 +01:00
Mohammad Azim Khan
9540261a76
Incorporated code review comments
2018-08-06 11:40:58 +01:00
Azim Khan
663d4702c5
Incorporate code review suggestions in mbedtls_test.py
2018-08-06 11:40:58 +01:00
Azim Khan
d59391afcd
Add support for sending hex parameters
2018-08-06 11:40:57 +01:00
Azim Khan
5e7f8df800
Print Greentea __testcase_name indicator for Greentea to mark the test
2018-08-06 11:40:57 +01:00
Mohammad Azim Khan
7a0d84fccc
On target test host test script
2018-08-06 11:40:57 +01:00