anomaly in dealing with SharedDomains
Nima Kaviani <nima.kaviani@...>
Hi,
I am trying to understand the expected behaviour when an already existing SharedDomain is redefined as either a shared or a private domain in CloudController. I have added the following test to *domain_validation.rb ... *note the validation part of the test which is highlighted. The following test does not pass in *private_domain_spec.rb* but it does pass for *shared_domain_spec.rb.* *context 'when the domains are exact match and it is already a shared domain' do* * before do* * SharedDomain.make name: 'foo.com <http://foo.com>'* * subject.name <http://subject.name> = 'foo.com <http://foo.com>'* * end* * it { is_expected.not_to be_valid }* *end* Now if I change the test to the following it passes in *private_domain_spec.rb* but it does not pass in* shared_domain_spec.rb*. *context 'when the domains are exact match and it is already a shared domain' do* * before do* * SharedDomain.make name: 'foo.com <http://foo.com>'* * subject.name <http://subject.name> = 'foo.com <http://foo.com>'* * end* * it { is_expected.to <http://is_expected.to> be_valid }* *end* so, what is the expected behaviour with regards to an already existing SharedDomain? does it allow for private domains to take over the name but not for other SharedDomains to not take over the name, or vice verse? or is it a bug in the way domain names get validated? thanks, -nima -- http://nima.magic.ubc.ca |
|