Start to add tests, try to automatically generate registry based on a setting