Optimized error exceptions.
test/unit: Added tests for Provider class