Skip to content

Add new test cases that represent usage of libtasn1

Ahmed Zaki requested to merge zaki_ahmed/libtasn1:master into master

This PR includes three new test cases

Test_gnutls.c Test_p11kit_1.c Test_swtpm.c

These test cases are extracted from gnutls, p11kit and swtpm respectively.

The test cases are automatically extracted from those projects.

These test cases provide two advantages:

1- They reflect how real-world clients are using the Libtasn1 APIs.

2- They provide additional code coverage in libtasn1.

Prior to adding those test cases coverage in /lib was as follows using 'make check':

  lines......: 87.6% (2903 of 3313 lines)
  functions..: 95.0% (96 of 101 functions)
  branches...: 71.3% (2108 of 2955 branches)

After adding these test cases coverage is increased as follows:

  lines......: 88.0% (2914 of 3313 lines)
  functions..: 96.0% (97 of 101 functions)
  branches...: 71.7% (2120 of 2955 branches)
  • Test suite updated with functionality tests

Reviewer's checklist:

  • There is a test suite reasonably covering new functionality or modifications
  • Function naming, parameters, return values, types, etc., are consistent with other code
  • This feature/change has adequate documentation added
  • No obvious mistakes in the code
Edited by Ahmed Zaki

Merge request reports