more generaloption

- bunch of minor fixes
- working unittests