test/resource_test.rb in loquor-0.6.0 vs test/resource_test.rb in loquor-0.7.0

- old
+ new

@@ -36,9 +36,15 @@ email = "foobar" Loquor.expects(:get).with("/foobar?email=#{email}").returns([]) Foobar.where(email: email).to_a end + def test_create_should_put_correct_params + payload = {bar: 'foo'} + Loquor.expects(:post).with("/foobar", payload: payload) + Foobar.create(payload) + end + def test_update_should_put_correct_params id = 8 payload = {bar: 'foo'} Loquor.expects(:put).with("/foobar/#{id}", payload: payload) Foobar.update(id, payload)