adding dispatchTest function