Exemple #1
0
 public void SetUp()
 {
     //_repository = new Repository(connectionString);
     _repository = new Repository();
     _generator  = Substitute.For <ShortUrlGenerator>();
     _logic      = new Business_Logic.CutUrlLogic(_repository, _generator);
 }
        public void Setup()
        {
            longUrl          = "https://docs.google.com/";
            expectedShortUrl = "cuturl.local/google";
            userId           = "1234";

            generator  = Substitute.For <IShortUrlGenerator>();
            repository = Substitute.For <IRepository>();
            //repository = new Repository();
            logic = new Business_Logic.CutUrlLogic(repository, generator);
        }
 public RedirectController(ICutUrlLogic urlLogic)
 {
     _urlLogic = urlLogic;
 }
 public ApiController(IUserManagement userManagement, ICutUrlLogic cutUrlLogic)
 {
     _userManagement = userManagement;
     _cutUrlLogic    = cutUrlLogic;
 }