spec/cfoundry/v2/domain_spec.rb in cfoundry-1.5.3 vs spec/cfoundry/v2/domain_spec.rb in cfoundry-2.0.0

- old
+ new

@@ -1,11 +1,14 @@ require "spec_helper" -describe CFoundry::V2::Domain do - let(:client) { fake_client } +module CFoundry + module V2 + describe Domain do + let(:space) { build(:space) } + let(:domain) { build(:domain, :spaces => [space]) } - subject { CFoundry::V2::Domain.new("domain-id-1", client) } - - it "should have a spaces association" do - expect(subject.spaces).to eq([]) + it "should have a spaces association" do + expect(domain.spaces).to eq([space]) + end + end end end