public virtual void MyTestInitialize() { this.DsmApiContext = ServiceLocator.Current.GetInstance <IDsmApiContext>(); this.DsmApiContext.LoadAllApiInfo().Wait(); AuthenticationApi authenticationApi = new AuthenticationApi(this.DsmApiContext); string account = ConfigurationManager.AppSettings["dsm_account"]; string password = ConfigurationManager.AppSettings["dsm_password"]; authenticationApi.LogOn(account, password).Wait(); }