diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-20 02:18:09 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-20 02:18:09 +0300 |
commit | 6ed4ec3e0b1340f96b7c043ef51d1b33bbe85fde (patch) | |
tree | dc4d20fe6064752c0bd323187252c77e0a89144b /spec/controllers/import/github_controller_spec.rb | |
parent | 9868dae7fc0655bd7ce4a6887d4e6d487690eeed (diff) |
Add latest changes from gitlab-org/gitlab@15-4-stable-eev15.4.0-rc42
Diffstat (limited to 'spec/controllers/import/github_controller_spec.rb')
-rw-r--r-- | spec/controllers/import/github_controller_spec.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/controllers/import/github_controller_spec.rb b/spec/controllers/import/github_controller_spec.rb index 46160aac0c1..269eb62cae6 100644 --- a/spec/controllers/import/github_controller_spec.rb +++ b/spec/controllers/import/github_controller_spec.rb @@ -134,7 +134,7 @@ RSpec.describe Import::GithubController do it 'fetches repos using legacy client' do expect_next_instance_of(Gitlab::LegacyGithubImport::Client) do |client| - expect(client).to receive(:repos) + expect(client).to receive(:repos).and_return([]) end get :status @@ -164,8 +164,8 @@ RSpec.describe Import::GithubController do end it 'fetches repos using latest github client' do - expect_next_instance_of(Octokit::Client) do |client| - expect(client).to receive(:repos).and_return([].to_enum) + expect_next_instance_of(Gitlab::GithubImport::Client) do |client| + expect(client).to receive(:repos).and_return([]) end get :status @@ -184,8 +184,8 @@ RSpec.describe Import::GithubController do context 'pagination' do context 'when no page is specified' do it 'requests first page' do - expect_next_instance_of(Octokit::Client) do |client| - expect(client).to receive(:repos).with(nil, { page: 1, per_page: 25 }).and_return([].to_enum) + expect_next_instance_of(Gitlab::GithubImport::Client) do |client| + expect(client).to receive(:repos).with({ page: 1, per_page: 25 }).and_return([]) end get :status |