Add tests.
Add middleware mapper generator.