public void ValidateCategory_ValidCategory_ReturnTrue()
        {
            var category = new Category
            {
                Name = "Test name",
                Description = "Test description",
                IconPath = "glyphicon-record",
                Type = CategoryType.Expense
            };

            var categoryService = new CategoryService(ProvidersFactory.GetNewTransactionsProviders());
            Assert.DoesNotThrow(() => categoryService.Validate(category));
        }
        public void ValidateCategory_EmptyName_ThrowException()
        {
            var category = new Category
            {
                Name = string.Empty,
                Description = "Test description",
                IconPath = "glyphicon-record",
                Type = CategoryType.Expense
            };

            var categoryService = new CategoryService(ProvidersFactory.GetNewTransactionsProviders());
            categoryService.Validate(category);
        }
 public void ValidateCategory_NullCategory_ThrowException()
 {
     var categoryService = new CategoryService(ProvidersFactory.GetNewTransactionsProviders());
     categoryService.Validate(null);
 }