public BasicResponse InsertPatrimonio(MarcaInsert marca) { BasicResponse r = new BasicResponse(); var login = new BasicLogin(User.Identity); if (!login.isAtutenticated) { r.Status = RequisitionStatus.ProcessedWithError; r.CodeStatus = CodeStatus.InvalidToken; r.Messages.Add("User not authnticated"); } else { r = Marca.insertMarca(marca); } return(r); }
public BasicResponse GetUsuario() { BasicResponse r = new BasicResponse(); var login = new BasicLogin(User.Identity); if (!login.isAtutenticated) { r.Status = RequisitionStatus.ProcessedWithError; r.CodeStatus = CodeStatus.InvalidToken; r.Messages.Add("User not authnticated"); } else { r = Usuario.getUsuario(); } return(r); }
public void CheckRecurringPayment() { List <dynamic> sites = ReadCSV.GetSites("Cases/RecurringPayment/CheckRecurringPaymentTestData.csv"); IWebDriver driver = StartUp(); try { for (int j = 0; j < sites.Count; j++) { try { BasicLogin.Execute(sites[j], driver); RecurringPayment.Execute(sites[j], driver); } catch (System.Exception ex) { throw ex; } finally { foreach (KeyValuePair <string, object> entry in sites[j]) { TestContext.WriteLine(entry.Key + ": " + entry.Value); } } } } catch (System.Exception ex) { throw ex; } finally { driver.Close(); driver.Dispose(); } }
public void CheckBasicLogin() { List <dynamic> sites = ReadCSV.GetSites(TestContext.Properties["BasicLoginTestDataPath"].ToString()); int siteCount = sites.Count; IWebDriver driver = StartUp(); try { for (int j = 0; j < siteCount; j++) { try { BasicLogin.Execute(sites[j], driver); } catch (System.Exception ex) { throw ex; } finally { foreach (KeyValuePair <string, object> entry in sites[j]) { TestContext.WriteLine(entry.Key + ": " + entry.Value); } } } } catch (System.Exception ex) { throw ex; } finally { driver.Close(); driver.Dispose(); } }
public Login_API(BasicLogin userData) { this.userData = userData; }