Change in pysim[master]: filesystem: add unit tests for encoder/decoder methods

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

fixeria gerrit-no-reply at lists.osmocom.org
Thu May 6 19:06:47 UTC 2021


fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/24012 )

Change subject: filesystem: add unit tests for encoder/decoder methods
......................................................................


Patch Set 4:

(4 comments)

Cosmetic comments first.

https://gerrit.osmocom.org/c/pysim/+/24012/4/pySim/ts_31_102.py 
File pySim/ts_31_102.py:

https://gerrit.osmocom.org/c/pysim/+/24012/4/pySim/ts_31_102.py@294 
PS4, Line 294:     _encode_decode_testvector = ['{"prot_scheme_id_list": [{"priority": 0, "identifier": 2, "key_index": 1}, {"priority": 1, "identifier": 1, "key_index": 2}, {"priority": 2, "identifier": 0, "key_index": 0}], "hnet_pubkey_list": [{"hnet_pubkey_identifier": 27, "hnet_pubkey": "0272da71976234ce833a6907425867b82e074d44ef907dfb4b3e21c1c2256ebcd1"}, {"hnet_pubkey_identifier": 30, "hnet_pubkey": "5a8d38864820197c3394b92613b20b91633cbd897119273bf8e4a6f4eec0a650"}]}']
This line looks way too long and IMO unreadable. Can we split it somehow? Or maybe even define as Python object and then convert to string somehow? This way you get error checking at load time.


https://gerrit.osmocom.org/c/pysim/+/24012/4/pySim/ts_31_103.py 
File pySim/ts_31_103.py:

https://gerrit.osmocom.org/c/pysim/+/24012/4/pySim/ts_31_103.py@121 
PS4, Line 121: 				 '{"addr": "hello,world", "addr_type": "00"}']
mixing tabs and spaces, let's avoid this


https://gerrit.osmocom.org/c/pysim/+/24012/4/pySim/ts_51_011.py 
File pySim/ts_51_011.py:

https://gerrit.osmocom.org/c/pysim/+/24012/4/pySim/ts_51_011.py@380 
PS4, Line 380: 				 '{"msisdn": [1, 3, "123456"]}']
mixing tabs and spaces, let's avoid this


https://gerrit.osmocom.org/c/pysim/+/24012/4/pySim/ts_51_011.py@471 
PS4, Line 471: 				 '{"imsi": "123456789012345"}']
same here and below



-- 
To view, visit https://gerrit.osmocom.org/c/pysim/+/24012
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I02d884547f4982e0b8ed7ef21b8cda75237942e2
Gerrit-Change-Number: 24012
Gerrit-PatchSet: 4
Gerrit-Owner: dexter <pmaier at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-Comment-Date: Thu, 06 May 2021 19:06:47 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210506/f20632f3/attachment.htm>


More information about the gerrit-log mailing list