-
- Downloads
Fix notification issues on HipChatService, add HipChatMessage specs
adding specs for HipChatMessage exposed some issues with the way I was building the matrix-commit style notification message, so it ended up being quite a bit more changes than I expected. The save call from the service configure form submits an empty string as the server URL if left blank, which I've indicated to do in order to use the default server, but Hash#merge will happily overwrite a full string with a blank string if asked, so we need to break that out, along with the worker options which get mutated into string hash keys, of which the HipChat client seems to not understand. Additionally, add another spec to make sure we call the Sidekiq worker with expected arguments.
Showing
- app/models/project_services/hip_chat_message.rb 29 additions, 15 deletionsapp/models/project_services/hip_chat_message.rb
- app/models/project_services/hip_chat_service.rb 19 additions, 6 deletionsapp/models/project_services/hip_chat_service.rb
- app/workers/hip_chat_notifier_worker.rb 12 additions, 3 deletionsapp/workers/hip_chat_notifier_worker.rb
- spec/models/project_services/hip_chat_message_spec.rb 65 additions, 0 deletionsspec/models/project_services/hip_chat_message_spec.rb
- spec/models/project_services/hip_chat_service_spec.rb 14 additions, 1 deletionspec/models/project_services/hip_chat_service_spec.rb
Please register or sign in to comment