cfoundry 2.3.0 → 2.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,7 +15,7 @@ module CFoundry::V2::ModelMagic
|
|
15
15
|
#
|
16
16
|
define_method(name) do
|
17
17
|
return @cache[name] if @cache.key?(name)
|
18
|
-
return @client.send(
|
18
|
+
return @client.send(association_name) unless persisted?
|
19
19
|
|
20
20
|
@cache[name] =
|
21
21
|
if @manifest && @manifest[:entity].key?(name)
|
data/lib/cfoundry/version.rb
CHANGED
@@ -10,6 +10,18 @@ module CFoundry
|
|
10
10
|
expect(domain.spaces).to eq([space])
|
11
11
|
end
|
12
12
|
|
13
|
+
describe "#owning_organization" do
|
14
|
+
context "when the domain is not persisted" do
|
15
|
+
let(:client) { build(:client) }
|
16
|
+
let(:domain) { build(:domain, client: client, guid: nil)}
|
17
|
+
it "asdf" do
|
18
|
+
client.should_not_receive(:owning_organization)
|
19
|
+
client.should_receive(:organization)
|
20
|
+
domain.owning_organization
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
13
25
|
describe "validations" do
|
14
26
|
subject { build(:domain) }
|
15
27
|
it { should validate_presence_of(:name) }
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cfoundry
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.3.
|
4
|
+
version: 2.3.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2013-07-
|
13
|
+
date: 2013-07-02 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: activemodel
|