Not from my phone. I'm at costco right now. Peobably head home before and 
    —
Mathieu

On Fri, Apr 4, 2014 at 3:19 PM, Charles Barbier <notifications@github.com>
wrote:

>> @@ -44,6 +44,18 @@
>>          xhr :post, :create, {:check => valid_attributes}, valid_session
>>          response.should be_ok
>>        end
>> +
>> +      context "email already present" do
>> +        before do
>> +          Check.create(valid_attributes)
>> +        end
>> +
>> +        it "overwrites the existing record rather than create a new one" do
>> +          expect {
>> +            xhr :post, :create, {:check => valid_attributes}, valid_session
>> +          }.to_not change(Check, :count).by(1)
> I wouldn't specify the `#by(1)` because if things goes really wrong it will create 2 and pass the test!
> ---
> Reply to this email directly or view it on GitHub:
> https://github.com/railsbridge-montreal/railsbridge-montreal-website/pull/67/files#r11309600