public VotesController( IVotesService votesService, IIssuesService issuesService) { this.votesService = votesService; this.issuesService = issuesService; }
public VotesController( UserManager <ApplicationUser> userManager, IVotesService voteServices) { this.userManager = userManager; this.voteServices = voteServices; }
public VotesController( IVotesService votesService, UserManager <ApplicationUser> userManager) { this.votesService = votesService; this.userManager = userManager; }
public VotesController( IVotesService votesService, IUsersService usersService) { this.votesService = votesService; this.usersService = usersService; }
public HomeController(IUsersService usersService, IPostsService postsService, IVotesService votesService, IVotesForCommentsService votesForCommentsService) { this.usersService = usersService; this.postsService = postsService; this.votesService = votesService; this.votesForCommentsService = votesForCommentsService; }
public AccountController(UserManager <ApplicationUser> userManager, SignInManager <ApplicationUser> signInManager, IVotesService votesService, IVotesForCommentsService votesForCommentsService, IUsersService usersService) { this.userManager = userManager; this.votesService = votesService; this.votesForCommentsService = votesForCommentsService; this.usersService = usersService; this.signInManager = signInManager; }
public UsersController(IUsersService usersService, IPostsService postsService, IVotesService votesService, IVotesForCommentsService votesForCommentsService, UserManager <ApplicationUser> userManager) { this.usersService = usersService; this.postsService = postsService; this.votesService = votesService; this.votesForCommentsService = votesForCommentsService; this.userManager = userManager; }
public HomeController(IUserAccService userAccService, IUserInfo userInfoService, IVotesService votesService) { this.userAccService = userAccService; this.userInfoService = userInfoService; this.votesService = votesService; }
public VotesController( UserManager <ApplicationUser> userManager, IVotesService votesService, IImagesService imagesService) { this.UserManager = userManager; this.VotesService = votesService; this.ImagesService = imagesService; }
public VotesController( IPostsService postsService, IVotesService votesService, ICommentsService commentsService) { this.postsService = postsService; this.votesService = votesService; this.commentsService = commentsService; }
public CategoriesService( IDeletableEntityRepository <Category> categoriesRepository, IDeletableEntityRepository <Recipe> recipesRepository, IVotesService votesService) { this.categoriesRepository = categoriesRepository; this.recipesRepository = recipesRepository; this.votesService = votesService; }
public SellersController( IUsersService usersService, IRolesService rolesService, IUserRolesService<ApplicationUserRole> userRolesService, ICommentsService commentsService, IVotesService votesService, IProductsService productsService) : base(usersService, rolesService, userRolesService, commentsService, votesService, productsService) { }
public ProductsController( IProductsService productsService, IIdentifierProvider identifierProvider, IVotesService votesService, IMappingService mappingService) { this.productsService = productsService; this.votesService = votesService; this.identifierProvider = identifierProvider; this.mappingService = mappingService; }
public AbstractVotesController( ApiSettings settings, ILogger <AbstractVotesController> logger, ITransactionCoordinator transactionCoordinator, IVotesService votesService, IApiVotesModelMapper votesModelMapper ) : base(settings, logger, transactionCoordinator) { this.VotesService = votesService; this.VotesModelMapper = votesModelMapper; }
public VotesServiceTests() { this.votes = new List <Vote>(); var surveysRepository = new EfDeletableEntityRepository <Survey>(this.DbContext); var votesRepository = new EfRepository <Vote>(this.DbContext); this.service = new VotesService(votesRepository); this.InitializeRepositoriesData(); }
public RecipesController( ICategoriesService categoriesService, IRecipesService recipesService, UserManager <ApplicationUser> userManager, IVotesService votesService, ICommentsService commentsService) { this.categoriesService = categoriesService; this.recipesService = recipesService; this.userManager = userManager; this.votesService = votesService; this.commentsService = commentsService; }
public async Task SetUp() { var options = new DbContextOptionsBuilder <ApplicationDbContext>() .UseInMemoryDatabase(databaseName: "votesTestDb").Options; this.dbContext = new ApplicationDbContext(options); await this.dbContext.Database.EnsureDeletedAsync(); var postVoteRepository = new EfDeletableEntityRepository <UserPostVote>(this.dbContext); var postRepository = new EfDeletableEntityRepository <Post>(this.dbContext); this.votesService = new VotesService(postVoteRepository, postRepository); }
public async Task GetVotes_WithDummyData_ShouldReturnCorrectResult() { var errorMessagePrefix = "VotesService GetVotesAsync() method does not work properly."; var dbContext = ApplicationDbContextInMemoryFactory.InitializeContext(); await this.SeedData(dbContext); this.votesService = new VotesService(dbContext); var expectedResult = dbContext.Votes.First().ServiceId; var actualResult = await this.votesService.GetVotesAsync <VotesServiceModel>(expectedResult); Assert.True(expectedResult == actualResult.Id, errorMessagePrefix + " " + "Id is not return properly."); }
public RecipesService( Cloudinary cloudinary, IDeletableEntityRepository <Image> imagesRepository, IDeletableEntityRepository <Recipe> recipesRepository, IRepository <UserRecipe> userRecipes, IDeletableEntityRepository <Vote> votesRepository, IVotesService votesService) { this.cloudinary = cloudinary; this.imagesRepository = imagesRepository; this.recipesRepository = recipesRepository; this.userRecipesRepository = userRecipes; this.votesRepository = votesRepository; this.votesService = votesService; }
public AnimalService( IRepository <AnimalImage> animalImagesRepository, IDeletableEntityRepository <Animal> animalsRepository, UserManager <ApplicationUser> userManager, Cloudinary cloudinary, ICloudinaryService cloudinaryService, IVotesService votesService) { this.animalImagesRepository = animalImagesRepository; this.animalsRepository = animalsRepository; this.userManager = userManager; this.cloudinary = cloudinary; this.cloudinaryService = cloudinaryService; this.votesService = votesService; }
public SuggestionsController( ISuggestionsService suggestionsService, UserManager <ApplicationUser> userManager, ICloudinaryHelper cloudinaryHelper, Cloudinary cloudinary, IVotesService votesService, IGamesService gamesService) { this.suggestionsService = suggestionsService; this.userManager = userManager; this.cloudinaryHelper = cloudinaryHelper; this.cloudinary = cloudinary; this.votesService = votesService; this.gamesService = gamesService; }
public async Task Create_WithNoVotes_ShouldThrowArgumentNullException() { var dbContext = ApplicationDbContextInMemoryFactory.InitializeContext(); this.votesService = new VotesService(dbContext); var testVotesService = new VotesServiceModel { Type = VoteType.UpVote, ServiceId = 1, UserId = Guid.NewGuid().ToString(), }; await Assert.ThrowsAsync <ArgumentNullException>(async() => await this.votesService.CreateVoteAsync(testVotesService)); }
public VotesController( ApiSettings settings, ILogger <VotesController> logger, ITransactionCoordinator transactionCoordinator, IVotesService votesService, IApiVotesModelMapper votesModelMapper ) : base(settings, logger, transactionCoordinator, votesService, votesModelMapper) { this.BulkInsertLimit = 250; this.MaxLimit = 1000; this.DefaultLimit = 250; }
public async Task Create_WithDummyData_ShouldReturnCorrectResult() { var dbContext = ApplicationDbContextInMemoryFactory.InitializeContext(); await this.SeedData(dbContext); this.votesService = new VotesService(dbContext); var testVotesService = new VotesServiceModel { Type = VoteType.UpVote, ServiceId = 1, UserId = Guid.NewGuid().ToString(), }; var expectedResult = 3; var actualResult = await this.votesService.CreateVoteAsync(testVotesService); Assert.Equal(expectedResult, actualResult); }
public VotesController(IVotesService votes) { _votes = votes; }
public VotesController(IVotesService votesService) { this.votesService = votesService; }
public CandidatesController(IVotesService votesService, ICandidatesService candidatesService) { _votesService = votesService; _candidatesService = candidatesService; }
public VotesController(IVotesService votes, IIdeasService ideas) { this.votes = votes; this.ideas = ideas; }
public VotesController(IVotesService votesService, IRepository <Vote> votesRepository) { this.votesService = votesService; this.votesRepository = votesRepository; }
public VotesController(IArticlesService articles, IIdentifierProvider identifierProvider, IVotesService votes) { this.articles = articles; this.identifierProvider = identifierProvider; this.votes = votes; }
public VotesController(IVotesService votes) { this.votes = votes; }
public VotesController(IVotesService service, UserManager <ApplicationUser> manager) { this.service = service; this.manager = manager; }
public VoteController(IVotesService _voteService) { this._voteService = _voteService; }
public VotesController(IVotesService votesService, IForumVotesService forumVotesService) { this.votesService = votesService; this.forumVotesService = forumVotesService; }