test/lib/vedeu/dsl/interface_test.rb in vedeu-0.6.8 vs test/lib/vedeu/dsl/interface_test.rb in vedeu-0.6.9
- old
+ new
@@ -7,11 +7,11 @@
describe Interface do
let(:described) { Vedeu::DSL::Interface }
let(:instance) { described.new(model, client) }
let(:model) {
- Vedeu::Interface.new(name: _name)
+ Vedeu::Models::Interface.new(name: _name)
}
let(:_name) { 'actinium' }
let(:client) {}
describe '#initialize' do
@@ -27,11 +27,11 @@
described.interface('fluorine') do
# ...
end
}
- it { subject.must_be_instance_of(Vedeu::Interface) }
+ it { subject.must_be_instance_of(Vedeu::Models::Interface) }
context 'when the block is not given' do
subject { described.interface('fluorine') }
it { proc { subject }.must_raise(Vedeu::Error::InvalidSyntax) }
@@ -170,11 +170,11 @@
it { subject.must_equal(nil) }
end
context 'when the interface has a name' do
- before { Vedeu::Focus.reset }
+ before { Vedeu::Models::Focus.reset }
it { subject.must_equal(['actinium']) }
end
end
@@ -211,11 +211,11 @@
before { Vedeu.groups.reset }
subject { instance.group(_value) }
- it { subject.must_be_instance_of(Vedeu::Group) }
+ it { subject.must_be_instance_of(Vedeu::Models::Group) }
context 'when the value is empty or nil' do
let(:_value) { '' }
it { subject.must_equal(false) }
@@ -223,10 +223,11 @@
context 'when the named group exists' do
let(:members) { Set['actinium', 'lanthanum'] }
before do
- Vedeu::Group.new(name: 'elements', members: ['lanthanum']).store
+ Vedeu::Models::Group.new(name: 'elements',
+ members: ['lanthanum']).store
end
it {
subject
Vedeu.groups.find('elements').members.must_equal(members)