示例#1
0
 public CardService(IUnitOfWork uow)
 {
     this._Repository           = uow.GetRepository <Card>();
     this._getCardListComponent = new GetCardListComponent();
     this._addCardComponent     = new AddCardComponent();
     this._getCardByIDComponent = new GetCardByIDComponent();
     this._editCardComponent    = new EditCardComponent();
     this._deleteCardComponent  = new DeleteCardComponent();
 }
示例#2
0
 public void Setup()
 {
     this._deleteCardComponent = new DeleteCardComponent();
     this._mock = new Mock <IRepository <Card> >();
     this._card = new Card
     {
         Name        = "Bang!",
         ID          = 1,
         Description = "Kill 'Em All",
         Suit        = Suit.Spade,
         Rank        = Rank.Ace,
         Cardtype    = CardType.Basic,
         IsActive    = true
     };
 }