Ejemplo n.º 1
0
        public void PropertiesRequiredInvalid(string id, string companyId, string name, string country)
        {
            var manufacturer = EntitiesFactory.GetNewManufacturerParameterized(id, companyId, name, country);

            bool result = manufacturer.ValidatePropertiesRequired();

            result.Should().BeFalse();
        }
        public async void SaveInvalid(string id, string companyId, string name, string country)
        {
            var manufactured = EntitiesFactory.GetNewManufacturerParameterized(id, companyId, name, country);

            _manufacturedRepository.Save(manufactured).Returns(true);

            bool result = await _manufacturerService.Save(manufactured);

            result.Should().BeFalse();
        }
        public async void ImportInvalid(string id, string companyId, string name, string country)
        {
            var manufacturedInvalid = EntitiesFactory.GetNewManufacturerParameterized(id, companyId, name, country);
            List <Manufacturer> manufacturedList = EntitiesFactory.GetManufacturerList();

            manufacturedList.Add(manufacturedInvalid);
            _manufacturedRepository.Import(manufacturedList).Returns(true);

            bool result = await _manufacturerService.Import(manufacturedList);

            result.Should().BeFalse();
        }