Skip to content

Commit

Permalink
Remove delayed job functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
RandomTannenbaum committed Jul 3, 2024
1 parent 6fb4df1 commit 480e328
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 7 deletions.
2 changes: 0 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@ gem 'carrierwave'
gem 'config'
gem 'countries'
gem 'cssbundling-rails'
gem 'daemons'
gem 'database_cleaner'
gem 'delayed_job_active_record'
gem 'devise'
gem 'faker'
gem 'haml-rails'
Expand Down
3 changes: 0 additions & 3 deletions app/domain/ptime/update_people_data.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,8 @@ def run
skills_person.location = 'Bern'
skills_person.nationality = 'CH'
skills_person.save!

Ptime::UpdatePeopleData.run
end
end
# rubocop:enable Metrics
handle_asynchronously :run, :run_at => proc { 15.minutes.from_now }
end
end
4 changes: 2 additions & 2 deletions spec/domain/ptime/update_people_data_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@
to_return(body: employees.to_json, headers: { 'content-type': "application/vnd.api+json; charset=utf-8" }, status: 200)
.with(basic_auth: [ptime_api_test_username, ptime_api_test_password])

Ptime::UpdatePeopleData.new.run_without_delay
Ptime::UpdatePeopleData.new.run

expect(person_longmax.reload.email).to eq("[email protected]")
expect(person_alice.reload.title).to eq("MSc in some other field")
Expand Down Expand Up @@ -141,7 +141,7 @@
.with(basic_auth: [ptime_api_test_username, ptime_api_test_password])

Ptime::AssignEmployeeIds.new.run(should_map: true)
Ptime::UpdatePeopleData.new.run_without_delay
Ptime::UpdatePeopleData.new.run

new_employee_attributes = new_employee[:data].first[:attributes]
new_employee_name = "#{new_employee_attributes[:firstname]} #{new_employee_attributes[:lastname]}"
Expand Down

0 comments on commit 480e328

Please sign in to comment.