Пример #1
0
        public void CanDelete_should_not_throw_exception_if_not_locked()
        {
            var command = new DeleteField {
                FieldId = 1
            };

            GuardSchemaField.CanDelete(command, schema_0);
        }
Пример #2
0
        public void CanDelete_should_throw_exception_if_locked()
        {
            var command = new DeleteField {
                FieldId = 1
            };

            var schema_1 = schema_0.UpdateField(1, f => f.Lock());

            Assert.Throws <DomainException>(() => GuardSchemaField.CanDelete(command, schema_1));
        }