flapjack 1.3.0 → 1.4.0rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (37) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +7 -1
  3. data/bin/flapjack +11 -6
  4. data/etc/flapjack_config.yaml.example +4 -0
  5. data/features/steps/events_steps.rb +3 -3
  6. data/features/support/env.rb +2 -1
  7. data/lib/flapjack.rb +6 -0
  8. data/lib/flapjack/cli/flapper.rb +5 -0
  9. data/lib/flapjack/cli/import.rb +5 -0
  10. data/lib/flapjack/cli/maintenance.rb +5 -0
  11. data/lib/flapjack/cli/purge.rb +5 -0
  12. data/lib/flapjack/cli/receiver.rb +5 -0
  13. data/lib/flapjack/cli/server.rb +5 -0
  14. data/lib/flapjack/cli/simulate.rb +5 -0
  15. data/lib/flapjack/data/contact.rb +22 -35
  16. data/lib/flapjack/data/entity_check.rb +2 -2
  17. data/lib/flapjack/data/event.rb +2 -1
  18. data/lib/flapjack/data/notification.rb +4 -4
  19. data/lib/flapjack/gateways/aws_sns.rb +6 -11
  20. data/lib/flapjack/gateways/email.rb +18 -29
  21. data/lib/flapjack/gateways/jabber.rb +7 -13
  22. data/lib/flapjack/gateways/jsonapi.rb +10 -6
  23. data/lib/flapjack/gateways/pagerduty.rb +6 -11
  24. data/lib/flapjack/gateways/sms_messagenet.rb +6 -11
  25. data/lib/flapjack/gateways/sms_nexmo.rb +6 -11
  26. data/lib/flapjack/gateways/sms_twilio.rb +6 -11
  27. data/lib/flapjack/gateways/web.rb +7 -0
  28. data/lib/flapjack/pikelet.rb +3 -1
  29. data/lib/flapjack/utility.rb +14 -0
  30. data/lib/flapjack/version.rb +1 -1
  31. data/spec/lib/flapjack/data/contact_spec.rb +22 -2
  32. data/spec/lib/flapjack/pikelet_spec.rb +1 -0
  33. data/spec/service_consumers/pact_helper.rb +0 -2
  34. data/spec/service_consumers/pacts/flapjack-diner_v1.0.json +2095 -2095
  35. data/spec/spec_helper.rb +4 -3
  36. data/spec/support/jsonapi_helper.rb +2 -1
  37. metadata +4 -4
data/spec/spec_helper.rb CHANGED
@@ -1,3 +1,5 @@
1
+ Encoding.default_internal = 'UTF-8'
2
+
1
3
  if ENV['COVERAGE']
2
4
  require 'simplecov'
3
5
  SimpleCov.start do
@@ -8,8 +10,6 @@ if ENV['COVERAGE']
8
10
  end
9
11
  end
10
12
 
11
- $testing = true
12
-
13
13
  FLAPJACK_ENV = ENV["FLAPJACK_ENV"] || 'test'
14
14
  FLAPJACK_ROOT = File.join(File.dirname(__FILE__), '..')
15
15
  FLAPJACK_CONFIG = File.join(FLAPJACK_ROOT, 'etc', 'flapjack_config.yaml')
@@ -22,8 +22,9 @@ require 'webmock/rspec'
22
22
  WebMock.disable_net_connect!
23
23
 
24
24
  $:.unshift(File.dirname(__FILE__) + '/../lib')
25
- require 'flapjack/configuration'
26
25
 
26
+ require 'redis'
27
+ require 'flapjack/configuration'
27
28
 
28
29
  # Requires supporting files with custom matchers and macros, etc,
29
30
  # in ./support/ and its subdirectories.
@@ -52,7 +52,8 @@ module JsonapiHelper
52
52
  expect(last_response.headers['Access-Control-Allow-Origin']).to eq("*")
53
53
  unless last_response.status == 204
54
54
  expect(Flapjack.load_json(last_response.body)).to be_a(Enumerable)
55
- expect(last_response.headers['Content-Type']).to eq(Flapjack::Gateways::JSONAPI::JSONAPI_MEDIA_TYPE)
55
+ ct = "#{Flapjack::Gateways::JSONAPI::JSONAPI_MEDIA_TYPE}; charset=UTF-8"
56
+ expect(last_response.headers['Content-Type']).to eq(ct)
56
57
  end
57
58
  end
58
59
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flapjack
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.0
4
+ version: 1.4.0rc1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lindsay Holmwood
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2015-02-17 00:00:00.000000000 Z
14
+ date: 2015-03-12 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: dante
@@ -635,9 +635,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
635
635
  version: '0'
636
636
  required_rubygems_version: !ruby/object:Gem::Requirement
637
637
  requirements:
638
- - - ">="
638
+ - - ">"
639
639
  - !ruby/object:Gem::Version
640
- version: '0'
640
+ version: 1.3.1
641
641
  requirements: []
642
642
  rubyforge_project:
643
643
  rubygems_version: 2.4.5