Stubbing RestClient response in RSpec

前端 未结 3 1922
长情又很酷
长情又很酷 2021-02-20 03:18

I have the following spec...

  describe \"successful POST on /user/create\" do
    it \"should redirect to dashboard\" do
      post \'/user/create\', {
                 


        
3条回答
  •  -上瘾入骨i
    2021-02-20 04:01

    I would consider using a gem for a task like this.

    Two of the most popular are WebMock and VCR.

提交回复
热议问题