Unit tests for public Sysconfig api

* added test helpers
* added sample test files
* minor changes to Sysconfig code