public async Task RequestGoogleGmailData() { await _googleAuthenticator.LoginGoogle(_testUsername); var gmailService = new GoogleGmailService(_googleAuthenticator.GetCurrentCredentials()); gmailService.CreateService(); Assert.IsNotNull(gmailService.GetData()); }
/// <summary> /// Get latest mails from current user his/her gmail /// </summary> /// <returns>A list of mails in GoogleGmailModel</returns> public List<GoogleGmailModel> GetGmailsUser() { var googleGmailService = new GoogleGmailService(_credential); googleGmailService.CreateService(); return googleGmailService.GetData(); }