public ActionResult <SettingDto> PostSettings(SettingDto settingDto)
        {
            settingDto = _service.Add(settingDto);
            _service.Save();

            return(settingDto);
        }
Example #2
0
        public void AddSetting()
        {
            _service.Add(new SettingDto {
                Id = "3", Name = "name3", Enabled = true
            });
            _service.Save();

            var result = _service.GetAll();
            var count  = result.Count();

            Assert.AreEqual(3, count);
        }