Fix: #284 FetchInstanceInfoWorkerが原因でSidekiqのJobが詰まる問題 (#342)

* Fix: #284 `FetchInstanceInfoWorker`が原因でSidekiqのJobが詰まる問題

* Fix: InstanceInfoを取得するタイミング

* Fix test

* Fix test

* Fix: HTTPコード

* 調整
This commit is contained in:
KMY(雪あすか) 2023-12-12 09:52:08 +09:00 committed by GitHub
parent 903b9ad347
commit 5173481ab7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 44 additions and 58 deletions

View file

@ -1,19 +0,0 @@
# frozen_string_literal: true
require 'rails_helper'
describe Scheduler::UpdateInstanceInfoScheduler do
let(:worker) { described_class.new }
before do
stub_request(:get, 'https://example.com/.well-known/nodeinfo').to_return(status: 200, body: '{}')
Fabricate(:account, domain: 'example.com')
Instance.refresh
end
describe 'perform' do
it 'runs without error' do
expect { worker.perform }.to_not raise_error
end
end
end