code-corps / code-corps/code-corps-api

Write test for StripeConnectAccount.update_from_stripe/1

Đang mở
#628 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Elixir
Star
234
Fork
82
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

# Problem

Test should ensure the function returns an {:ok, %StripeConnectAccount{}} with valid data. It should also ensure that the record was actually updated with data from stripe testing.

An additional test should ensure that, if there is no local record with the specified `id_from_stripe`, the response is `{:error, :not_found}`

Lastly, a test should ensure that, if the attributes provided contain invalid data, an `{:error, changeset}` is returned.

### Something we cannot test right now, since we do not have the infrastructure
* If the stripe API raises an error, it returns `{:error, %StripeAPIErrorResponse{}}`

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.