added some middleware
started some acceptance tests