spec/restspec/schema/dsl_spec.rb in restspec-0.1 vs spec/restspec/schema/dsl_spec.rb in restspec-0.2
- old
+ new
@@ -48,33 +48,9 @@
attribute = dsl.schema.attributes.values.first
expect(attribute.name).to eq('attr_name')
expect(attribute.type).to eq(type_instance)
end
-
- context 'when the :for option is just for checks' do
- let(:attribute) { dsl.attribute('attr_name', type_instance, for: [:checks]) }
-
- it 'is not allowed to generate examples' do
- expect(attribute.can_generate_examples?).to eq(false)
- end
-
- it 'is allowed to run in validations' do
- expect(attribute.can_be_checked?).to eq(true)
- end
- end
-
- context 'when the :for option is just for examples' do
- let(:attribute) { dsl.attribute('attr_name', type_instance, for: [:examples]) }
-
- it 'is allowed to generate examples' do
- expect(attribute.can_generate_examples?).to eq(true)
- end
-
- it 'is not allowed to run in validations' do
- expect(attribute.can_be_checked?).to eq(false)
- end
- end
end
describe '#include_attributes' do
let(:main_dsl) { DSL.new }
let(:schema_dsl) { SingleSchemaDSL.new(:name, main_dsl.send(:mixins)) }