filesystem: add unit tests for encoder/decoder methods

Lets add test vectors for the per-record/per-file encode/decode of
our various classes for the Elementary Files.

We keep the test vectors as class variables of the respective EF-classes
to ensure implementation and test vectors are next to each other.

The test classes then iterate over all EF subclasses and execute the
decode/encode functions using the test vectors from the class variables.

Change-Id: I02d884547f4982e0b8ed7ef21b8cda75237942e2
Related: OS#4963
This commit is contained in:
Harald Welte
2023-01-27 19:26:12 +01:00
parent d2edd414a8
commit 865eea68c3
7 changed files with 523 additions and 13 deletions

View File

@@ -124,6 +124,7 @@ class EF_UServiceTable(TransparentEF):
# TS 31.102 Section 4.4.2.1
class EF_PBR(LinFixedEF):
# TODO: a80ac0034f3a02c5034f0904aa0acb034f3d07c2034f4a06
def __init__(self, fid='4F30', name='EF.PBR', desc='Phone Book Reference', **kwargs):
super().__init__(fid, name=name, desc=desc, **kwargs)
#self._tlv = FIXME