/// <summary> /// Jory A. Wernette /// Created: 2021/05/10 /// /// Creates a new Collection record /// </summary> /// /// <param name="email"> The email of the Player creating the collection record</param> /// <param name="cardName"> The name of the card to be added to the collection</param> /// <param name="cardLocation"> The location where the card will be stored/used</param> /// <exception>No Collection created</exception> /// <returns>Bool denoting success or failure</returns> public bool AddCardToMyCollection(string email, string cardName, string cardLocation) { bool result = false; try { result = collectionAccessor.AddCardToMyCollection(email, cardName, cardLocation); } catch (Exception ex) { throw new ApplicationException("Collection Not Available.", ex); } return(result); }
public void TestAddCardToMyCollection() { //Arrange string email = "*****@*****.**"; string cardName = "Man-Eater Bug"; string cardLocation = "Effect Monster Box"; bool expectedResult = true; //Act bool actualResult = false; actualResult = collectionAccessor.AddCardToMyCollection(email, cardName, cardLocation); //Assert Assert.AreEqual(expectedResult, actualResult); }