diff options
author | Kamil Trzcinski <ayufan@ayufan.eu> | 2016-08-16 00:29:07 +0300 |
---|---|---|
committer | Kamil Trzcinski <ayufan@ayufan.eu> | 2016-08-16 00:29:07 +0300 |
commit | 8de2f5b103f84a76ff941a80ac7fc0bb934b480f (patch) | |
tree | 810cb183f99593ebb964feca90a1f6051bf70617 /spec/models/project_services/irker_service_spec.rb | |
parent | d626c1d3729f500a891a6934ea779136671ef8b2 (diff) | |
parent | e8aab1cd1550dd14408ae4c7b51f45110898b949 (diff) |
Merge branch 'fix-failing-tests' into pipeline-hooks-without-slack
Diffstat (limited to 'spec/models/project_services/irker_service_spec.rb')
-rw-r--r-- | spec/models/project_services/irker_service_spec.rb | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/spec/models/project_services/irker_service_spec.rb b/spec/models/project_services/irker_service_spec.rb index 3bed0e6093f..ec092297f4f 100644 --- a/spec/models/project_services/irker_service_spec.rb +++ b/spec/models/project_services/irker_service_spec.rb @@ -54,19 +54,20 @@ describe IrkerService, models: true do let(:colorize_messages) { '1' } before do + @irker_server = TCPServer.new 'localhost', 0 + allow(irker).to receive_messages( - active: true, - project: project, - project_id: project.id, - service_hook: true, - server_host: 'localhost', - server_port: 6659, - default_irc_uri: 'irc://chat.freenode.net/', - recipients: recipients, - colorize_messages: colorize_messages) + active: true, + project: project, + project_id: project.id, + service_hook: true, + server_host: @irker_server.addr[2], + server_port: @irker_server.addr[1], + default_irc_uri: 'irc://chat.freenode.net/', + recipients: recipients, + colorize_messages: colorize_messages) irker.valid? - @irker_server = TCPServer.new 'localhost', 6659 end after do |