Pass in params rather than reduntant code for tests