remove unused oauth2 middleware
add tests to validate inheriting from base FormatMiddleware