Attention is currently required from: fixeria, dexter.
laforge 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 12:
(8 comments)
File pySim/ts_31_102.py:
https://gerrit.osmocom.org/c/pysim/+/24012/comment/8306d6c9_6f6f420b
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"}]}']
> I agree that this line is not easy to read but
you can copy+paste it into pySim-shell and it will […]
I went for python notation
and not json/string, after all.
File pySim/ts_31_103.py:
https://gerrit.osmocom.org/c/pysim/+/24012/comment/622848fe_430bacb9
PS4, Line 121: '{"addr": "hello,world",
"addr_type": "00"}']
mixing tabs and spaces, let's avoid this
Done
File pySim/ts_51_011.py:
https://gerrit.osmocom.org/c/pysim/+/24012/comment/512a1cad_6cc2c6f1
PS4, Line 380: '{"msisdn": [1, 3, "123456"]}']
mixing tabs and spaces, let's avoid this
Done
https://gerrit.osmocom.org/c/pysim/+/24012/comment/e94016e8_40f2a18c
PS4, Line 471: '{"imsi": "123456789012345"}']
same here and below
Done
File tests/test_files.py:
https://gerrit.osmocom.org/c/pysim/+/24012/comment/7b14c796_b793f241
PS4, Line 57: for testvec_json in ef.__class__._encode_decode_testvector:
The problem without subTest is that it simply stops a
the first assert and doesn't continue to check […]
Done
https://gerrit.osmocom.org/c/pysim/+/24012/comment/581c3dc7_ef50436c
PS4, Line 71: testcase.assertEqual(testvec_json, decoded_json)
In my opinion matching the strings is the best way
possible. […]
Done
https://gerrit.osmocom.org/c/pysim/+/24012/comment/bf84e410_a9d10118
PS4, Line 94: for obj in gc.get_objects():
we already have utils.py:all_subclasses() for getting
that recursive list.
Done
https://gerrit.osmocom.org/c/pysim/+/24012/comment/d0d6d5f7_2a3b908d
PS4, Line 96: if not file_in_list(test_candidates, obj.name):
Ack
Done
--
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: 12
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-CC: Falkenber9 <robert.falkenberg(a)tu-dortmund.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 31 Jan 2023 19:59:29 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: comment