redhat-qe-security / SCAutolib

Library for automation of smart card testing
GNU General Public License v3.0
3 stars 10 forks source link

Class for config file #36

Closed x00Pavel closed 2 years ago

x00Pavel commented 2 years ago

Create a class for the standard creation of config files for that would be edited in the test. There are already 4 places in the library where the same code is used:

  1. Create ConfigParser object: 3 lines (instantiate + set a default value for the object)
  2. set value: several lines depending on how much editing would be done
  3. Write: 2 - 3 lines

All this can be replaced with a class that inherited ConfigParser class and all workflow would by in 3 lines:

  1. Instatiate - all values are set in the constructor
  2. Set value - method could take a list of fields that need to be edited
  3. Write
x00Pavel commented 2 years ago

Resolved in PR