Add tests for transforms __init__.
Move cache_key getter into base.
pep8.