gov_fake_notify 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +11 -0
  3. data/.rspec +3 -0
  4. data/.rubocop.yml +3 -0
  5. data/.rubocop_todo.yml +15 -0
  6. data/.ruby-version +1 -0
  7. data/.travis.yml +6 -0
  8. data/Gemfile +9 -0
  9. data/Gemfile.lock +87 -0
  10. data/LICENSE.txt +21 -0
  11. data/README.md +271 -0
  12. data/Rakefile +8 -0
  13. data/bin/console +15 -0
  14. data/bin/setup +8 -0
  15. data/exe/gov_fake_notify +5 -0
  16. data/gov_fake_notify.gemspec +40 -0
  17. data/lib/gov_fake_notify/attachment_store.rb +48 -0
  18. data/lib/gov_fake_notify/cli/root.rb +53 -0
  19. data/lib/gov_fake_notify/cli.rb +3 -0
  20. data/lib/gov_fake_notify/commands/create_template_command.rb +35 -0
  21. data/lib/gov_fake_notify/commands/fetch_all_messages_status_command.rb +45 -0
  22. data/lib/gov_fake_notify/commands/fetch_file_command.rb +41 -0
  23. data/lib/gov_fake_notify/commands/fetch_message_status_command.rb +44 -0
  24. data/lib/gov_fake_notify/commands/fetch_templates_command.rb +43 -0
  25. data/lib/gov_fake_notify/commands/send_email_command.rb +153 -0
  26. data/lib/gov_fake_notify/config.rb +42 -0
  27. data/lib/gov_fake_notify/control_app.rb +31 -0
  28. data/lib/gov_fake_notify/current_service.rb +22 -0
  29. data/lib/gov_fake_notify/files_app.rb +41 -0
  30. data/lib/gov_fake_notify/iodine.rb +9 -0
  31. data/lib/gov_fake_notify/notifications_app.rb +58 -0
  32. data/lib/gov_fake_notify/root_app.rb +23 -0
  33. data/lib/gov_fake_notify/store.rb +27 -0
  34. data/lib/gov_fake_notify/templates_app.rb +32 -0
  35. data/lib/gov_fake_notify/version.rb +5 -0
  36. data/lib/gov_fake_notify.rb +72 -0
  37. data/lib/views/files/confirm.html.erb +118 -0
  38. data/lib/views/files/download.html.erb +119 -0
  39. data/lib/views/govuk/file.html.erb +3 -0
  40. data/lib/views/govuk/horizontal_line.html.erb +1 -0
  41. data/lib/views/govuk/paragraph.html.erb +1 -0
  42. data/lib/views/govuk/show.html.erb +19 -0
  43. data/lib/views/layouts/govuk.html.erb +64 -0
  44. metadata +219 -0
@@ -0,0 +1,72 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'gov_fake_notify/version'
4
+ require 'gov_fake_notify/config'
5
+ require 'gov_fake_notify/root_app'
6
+ require 'gov_fake_notify/cli'
7
+
8
+ module GovFakeNotify
9
+ class Error < StandardError; end
10
+
11
+ def self.config
12
+ Config.instance.tap do |instance|
13
+ if block_given?
14
+ yield instance
15
+ configure_mail
16
+ configure_templates
17
+ configure_api_keys
18
+ end
19
+ end
20
+ end
21
+
22
+ def self.configure_mail
23
+ our_config = config
24
+ Mail.defaults do
25
+ case our_config.delivery_method.to_s
26
+ when 'smtp'
27
+ delivery_method :smtp, address: our_config.smtp_address, port: our_config.smtp_port
28
+ when 'test'
29
+ delivery_method :test
30
+ end
31
+ end
32
+ end
33
+
34
+ def self.configure_templates(store: Store.instance)
35
+ config.include_templates.each do |t|
36
+ template = t.transform_keys(&:to_s)
37
+ next if store.transaction { store.root?("template-#{template['id']}") }
38
+
39
+ store.transaction { store["template-#{template['id']}"] = template.dup }
40
+ end
41
+ end
42
+
43
+ def self.configure_api_keys(store: Store.instance)
44
+ config.include_api_keys.each do |k|
45
+ api_key = k.transform_keys(&:to_s)
46
+ next if store.transaction { store.root?("apikey-#{api_key['key']}") }
47
+
48
+ store.transaction do
49
+ key = api_key.dup
50
+ secret_token = key['key']
51
+ key['service_id'] = secret_token[-73..-38]
52
+ key['secret_token'] = secret_token[-36..-1]
53
+ store["apikey-#{api_key['key']}"] = key
54
+ end
55
+ end
56
+ end
57
+
58
+ def self.init
59
+ Config.instance # Pre load
60
+ FileUtils.mkdir_p GovFakeNotify.config.attachments_path
61
+ FileUtils.mkdir_p File.dirname(GovFakeNotify.config.database_file)
62
+ GovFakeNotify.configure_mail
63
+ GovFakeNotify.configure_templates
64
+ GovFakeNotify.configure_api_keys
65
+ end
66
+
67
+ def self.reset!
68
+ Store.clear_messages!
69
+ end
70
+ end
71
+
72
+ GovFakeNotify.init
@@ -0,0 +1,118 @@
1
+ <html lang="en" class="govuk-template ">
2
+
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <title>
6
+ You have a file to download
7
+
8
+ – GOV.UK
9
+ </title>
10
+ <meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
11
+ <meta name="theme-color" content="#0b0c0c">
12
+
13
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
14
+ </head>
15
+
16
+ <body class="govuk-template__body js-enabled">
17
+ <script>document.body.className = ((document.body.className) ? document.body.className + ' js-enabled' : 'js-enabled');</script>
18
+
19
+
20
+
21
+ <a href="#main-content" class="govuk-skip-link">Skip to main content</a>
22
+
23
+
24
+
25
+ <header class="govuk-header " role="banner" data-module="govuk-header">
26
+ <div class="govuk-header__container govuk-width-container">
27
+ <div class="govuk-header__logo">
28
+ <a href="/" class="govuk-header__link govuk-header__link--homepage">
29
+ <span class="govuk-header__logotype">
30
+ <svg role="presentation" focusable="false" class="govuk-header__logotype-crown"
31
+ xmlns="http://www.w3.org/2000/svg" viewBox="0 0 132 97" height="30" width="36">
32
+ <path fill="currentColor" fill-rule="evenodd"
33
+ d="M25 30.2c3.5 1.5 7.7-.2 9.1-3.7 1.5-3.6-.2-7.8-3.9-9.2-3.6-1.4-7.6.3-9.1 3.9-1.4 3.5.3 7.5 3.9 9zM9 39.5c3.6 1.5 7.8-.2 9.2-3.7 1.5-3.6-.2-7.8-3.9-9.1-3.6-1.5-7.6.2-9.1 3.8-1.4 3.5.3 7.5 3.8 9zM4.4 57.2c3.5 1.5 7.7-.2 9.1-3.8 1.5-3.6-.2-7.7-3.9-9.1-3.5-1.5-7.6.3-9.1 3.8-1.4 3.5.3 7.6 3.9 9.1zm38.3-21.4c3.5 1.5 7.7-.2 9.1-3.8 1.5-3.6-.2-7.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6 4.3-6.4 7.8-13.5 7.2-10.3-.9-10.9-8-11.2-13.8 2.5-.5 7.1 1.8 11 7.3L80.2 60c-4.1 4.4-8 5.3-12.3 5.4 1.4-4.4 8-11.6 8-11.6H55.5s6.4 7.2 7.9 11.6c-4.2-.1-8-1-12.3-5.4l1.4 16.4c3.9-5.5 8.5-7.7 10.9-7.3-.3 5.8-.9 12.8-11.1 13.8-7.2.6-12.9-2.9-13.5-7.2-.7-5 3.8-8.3 7.1-3.1 2.7-8.7-4.6-11.6-9.4-6.2 3.7-8.5 3.6-14.7-4.6-20.8-5.8 7.6-5 13.9 2.2 21.1-4.7-2.6-11.9.1-7.7 8.8 2.3-5.5 7.1-4.2 8.1.5.7 3.3-1.3 7.1-5.7 7.9-3.5.7-9-1.8-13.5-11.2 2.5.1 4.7 1.3 7.5 3.3l-4.7-15.4c-1.2 4.4-2.7 7.2-4.3 8.7-1.1-3-.9-5.3 0-10.2l-9.5 3.4c5 6.9 9.9 16.7 14 33.5 14.8-2.1 30.8-3.2 47.7-3.2z">
34
+ </path>
35
+ <image src="/static/images//govuk-logotype-crown.png" xlink:href=""
36
+ class="govuk-header__logotype-crown-fallback-image" width="36" height="32"></image>
37
+ </svg>
38
+ <span class="govuk-header__logotype-text">
39
+ GOV.UK
40
+ </span>
41
+ </span>
42
+
43
+ </a>
44
+ </div>
45
+
46
+ </div>
47
+ </header>
48
+
49
+
50
+
51
+ <div class="govuk-width-container ">
52
+
53
+ <main class="govuk-main-wrapper " id="main-content" role="main">
54
+
55
+ <div class="govuk-grid-row">
56
+ <div class="govuk-grid-column-two-thirds">
57
+ <h1 class="govuk-heading-l">
58
+
59
+ You have a file to download
60
+
61
+ </h1>
62
+
63
+ <p class="govuk-body"><%= service_name %> sent you a file to download.</p>
64
+ <p class="govuk-body">
65
+ If you’re not sure why you’ve been sent a file, or you have any questions,
66
+
67
+ email <a href="mailto:<%= service_email %>" class="govuk-link"><%= service_email %></a>.
68
+
69
+ </p>
70
+ <p class="govuk-body">
71
+
72
+
73
+
74
+
75
+ <a href="/files/download/<%= id %>"
76
+ role="button" draggable="false" class="govuk-button" data-module="govuk-button">
77
+ Continue
78
+ </a>
79
+ </p>
80
+
81
+ </div>
82
+ </div>
83
+
84
+ </main>
85
+ </div>
86
+
87
+
88
+
89
+ <footer class="govuk-footer " role="contentinfo">
90
+ <div class="govuk-width-container ">
91
+
92
+ <div class="govuk-footer__meta">
93
+ <div class="govuk-footer__meta-item govuk-footer__meta-item--grow">
94
+
95
+ <svg role="presentation" focusable="false" class="govuk-footer__licence-logo"
96
+ xmlns="http://www.w3.org/2000/svg" viewBox="0 0 483.2 195.7" height="17" width="41">
97
+ <path fill="currentColor"
98
+ d="M421.5 142.8V.1l-50.7 32.3v161.1h112.4v-50.7zm-122.3-9.6A47.12 47.12 0 0 1 221 97.8c0-26 21.1-47.1 47.1-47.1 16.7 0 31.4 8.7 39.7 21.8l42.7-27.2A97.63 97.63 0 0 0 268.1 0c-36.5 0-68.3 20.1-85.1 49.7A98 98 0 0 0 97.8 0C43.9 0 0 43.9 0 97.8s43.9 97.8 97.8 97.8c36.5 0 68.3-20.1 85.1-49.7a97.76 97.76 0 0 0 149.6 25.4l19.4 22.2h3v-87.8h-80l24.3 27.5zM97.8 145c-26 0-47.1-21.1-47.1-47.1s21.1-47.1 47.1-47.1 47.2 21 47.2 47S123.8 145 97.8 145">
99
+ </path>
100
+ </svg>
101
+ <span class="govuk-footer__licence-description">
102
+ All content is available under the
103
+ <a class="govuk-footer__link"
104
+ href="https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/" rel="license">Open
105
+ Government Licence v3.0</a>, except where otherwise stated
106
+ </span>
107
+ </div>
108
+ <div class="govuk-footer__meta-item">
109
+ <a class="govuk-footer__link govuk-footer__copyright-logo"
110
+ href="https://www.nationalarchives.gov.uk/information-management/re-using-public-sector-information/uk-government-licensing-framework/crown-copyright/">©
111
+ Crown copyright</a>
112
+ </div>
113
+ </div>
114
+ </div>
115
+ </footer>
116
+ </body>
117
+
118
+ </html>
@@ -0,0 +1,119 @@
1
+ <html lang="en" class="govuk-template ">
2
+
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <title>
6
+ Download your file
7
+
8
+ – GOV.UK
9
+ </title>
10
+ <meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
11
+ <meta name="theme-color" content="#0b0c0c">
12
+
13
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
14
+ </head>
15
+
16
+ <body class="govuk-template__body js-enabled">
17
+ <script>document.body.className = ((document.body.className) ? document.body.className + ' js-enabled' : 'js-enabled');</script>
18
+
19
+
20
+
21
+ <a href="#main-content" class="govuk-skip-link">Skip to main content</a>
22
+
23
+
24
+
25
+ <header class="govuk-header " role="banner" data-module="govuk-header">
26
+ <div class="govuk-header__container govuk-width-container">
27
+ <div class="govuk-header__logo">
28
+ <a href="/" class="govuk-header__link govuk-header__link--homepage">
29
+ <span class="govuk-header__logotype">
30
+ <svg role="presentation" focusable="false" class="govuk-header__logotype-crown"
31
+ xmlns="http://www.w3.org/2000/svg" viewBox="0 0 132 97" height="30" width="36">
32
+ <path fill="currentColor" fill-rule="evenodd"
33
+ d="M25 30.2c3.5 1.5 7.7-.2 9.1-3.7 1.5-3.6-.2-7.8-3.9-9.2-3.6-1.4-7.6.3-9.1 3.9-1.4 3.5.3 7.5 3.9 9zM9 39.5c3.6 1.5 7.8-.2 9.2-3.7 1.5-3.6-.2-7.8-3.9-9.1-3.6-1.5-7.6.2-9.1 3.8-1.4 3.5.3 7.5 3.8 9zM4.4 57.2c3.5 1.5 7.7-.2 9.1-3.8 1.5-3.6-.2-7.7-3.9-9.1-3.5-1.5-7.6.3-9.1 3.8-1.4 3.5.3 7.6 3.9 9.1zm38.3-21.4c3.5 1.5 7.7-.2 9.1-3.8 1.5-3.6-.2-7.7-3.9-9.1-3.6-1.5-7.6.3-9.1 3.8-1.3 3.6.4 7.7 3.9 9.1zm64.4-5.6c-3.6 1.5-7.8-.2-9.1-3.7-1.5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.4 1.4-4.4 8-11.6 8-11.6H55.5s6.4 7.2 7.9 11.6c-4.2-.1-8-1-12.3-5.4l1.4 16.4c3.9-5.5 8.5-7.7 10.9-7.3-.3 5.8-.9 12.8-11.1 13.8-7.2.6-12.9-2.9-13.5-7.2-.7-5 3.8-8.3 7.1-3.1 2.7-8.7-4.6-11.6-9.4-6.2 3.7-8.5 3.6-14.7-4.6-20.8-5.8 7.6-5 13.9 2.2 21.1-4.7-2.6-11.9.1-7.7 8.8 2.3-5.5 7.1-4.2 8.1.5.7 3.3-1.3 7.1-5.7 7.9-3.5.7-9-1.8-13.5-11.2 2.5.1 4.7 1.3 7.5 3.3l-4.7-15.4c-1.2 4.4-2.7 7.2-4.3 8.7-1.1-3-.9-5.3 0-10.2l-9.5 3.4c5 6.9 9.9 16.7 14 33.5 14.8-2.1 30.8-3.2 47.7-3.2z">
34
+ </path>
35
+ <image src="/static/images//govuk-logotype-crown.png" xlink:href=""
36
+ class="govuk-header__logotype-crown-fallback-image" width="36" height="32"></image>
37
+ </svg>
38
+ <span class="govuk-header__logotype-text">
39
+ GOV.UK
40
+ </span>
41
+ </span>
42
+
43
+ </a>
44
+ </div>
45
+
46
+ </div>
47
+ </header>
48
+
49
+
50
+
51
+ <div class="govuk-width-container ">
52
+
53
+ <main class="govuk-main-wrapper " id="main-content" role="main">
54
+
55
+ <div class="govuk-grid-row">
56
+ <div class="govuk-grid-column-two-thirds">
57
+ <h1 class="govuk-heading-l">
58
+
59
+ Download your file
60
+
61
+ </h1>
62
+
63
+ <p class="govuk-body">
64
+ Save your file somewhere you can find it. You may need to print it or show it to someone later.
65
+ </p>
66
+
67
+ <p class="govuk-body">
68
+ Check the email that <%= service_name %> sent you for more information.
69
+ </p>
70
+
71
+ <p class="govuk-body">
72
+ <a href="/files/<%= id %>"
73
+ download="" class="govuk-link">Download this file to your device</a>
74
+ </p>
75
+
76
+ <p class="govuk-body">
77
+ If you have any questions,
78
+
79
+ email <a href="mailto:<%= service_email %>" class="govuk-link"><%= service_email %></a>.
80
+
81
+ </p>
82
+
83
+ </div>
84
+ </div>
85
+
86
+ </main>
87
+ </div>
88
+
89
+
90
+
91
+ <footer class="govuk-footer " role="contentinfo">
92
+ <div class="govuk-width-container ">
93
+
94
+ <div class="govuk-footer__meta">
95
+ <div class="govuk-footer__meta-item govuk-footer__meta-item--grow">
96
+
97
+ <svg role="presentation" focusable="false" class="govuk-footer__licence-logo"
98
+ xmlns="http://www.w3.org/2000/svg" viewBox="0 0 483.2 195.7" height="17" width="41">
99
+ <path fill="currentColor"
100
+ d="M421.5 142.8V.1l-50.7 32.3v161.1h112.4v-50.7zm-122.3-9.6A47.12 47.12 0 0 1 221 97.8c0-26 21.1-47.1 47.1-47.1 16.7 0 31.4 8.7 39.7 21.8l42.7-27.2A97.63 97.63 0 0 0 268.1 0c-36.5 0-68.3 20.1-85.1 49.7A98 98 0 0 0 97.8 0C43.9 0 0 43.9 0 97.8s43.9 97.8 97.8 97.8c36.5 0 68.3-20.1 85.1-49.7a97.76 97.76 0 0 0 149.6 25.4l19.4 22.2h3v-87.8h-80l24.3 27.5zM97.8 145c-26 0-47.1-21.1-47.1-47.1s21.1-47.1 47.1-47.1 47.2 21 47.2 47S123.8 145 97.8 145">
101
+ </path>
102
+ </svg>
103
+ <span class="govuk-footer__licence-description">
104
+ All content is available under the
105
+ <a class="govuk-footer__link"
106
+ href="https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/" rel="license">Open
107
+ Government Licence v3.0</a>, except where otherwise stated
108
+ </span>
109
+ </div>
110
+ <div class="govuk-footer__meta-item">
111
+ <a class="govuk-footer__link govuk-footer__copyright-logo"
112
+ href="https://www.nationalarchives.gov.uk/information-management/re-using-public-sector-information/uk-government-licensing-framework/crown-copyright/">©
113
+ Crown copyright</a>
114
+ </div>
115
+ </div>
116
+ </div>
117
+ </footer>
118
+ </body>
119
+ </html>
@@ -0,0 +1,3 @@
1
+ <a style="word-wrap:break-word;color:#005ea5" href="<%= base_url %>/files/confirm/<%= File.basename file_data['file'] %>" target="_blank">
2
+ <%= base_url %>/files/confirm/<%= File.basename file_data['file'] %>
3
+ </a>
@@ -0,0 +1 @@
1
+ <hr style="border:0;height:1px;background:#bfc1c3;Margin:30px 0 30px 0" />
@@ -0,0 +1 @@
1
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c"><%= content %></p>
@@ -0,0 +1,19 @@
1
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Claim number: 262000200400</p>
2
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Gary Taylor</p>
3
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Thank you for submitting your claim to an employment tribunal.</p>
4
+ <hr style="border:0;height:1px;background:#bfc1c3;Margin:30px 0 30px 0">
5
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">WHAT HAPPENS NEXT</p>
6
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">We’ll contact you once we have sent your claim to the respondent and explain what happens next.<br>At present, this is taking us an average of 25 days.<br>Once we have sent them your claim, the respondent has 28 days to reply.</p>
7
+ <hr style="border:0;height:1px;background:#bfc1c3;Margin:30px 0 30px 0">
8
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">SUBMISSION DETAILS</p>
9
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Claim submitted: 09 October 2020<br>Tribunal office: Midlands (East) ET<br>Contact: <a href="mailto:midlandseastet@justice.gov.uk" target="_blank">midlandseastet@justice.gov.uk</a>, 0115 947 5701</p>
10
+ <hr style="border:0;height:1px;background:#bfc1c3;Margin:30px 0 30px 0">
11
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Please use the link below to download a copy of your claim.<br><a style="word-wrap:break-word;color:#005ea5" href="https://documents.service.gov.uk/d/f8FKyAk4SCeu4_sjf5zV5w/p0-ZUPWESuGUsbUdomOoHQ?key=VvieEVMIEWUZTKZQWPR4Lb4HWCeCwVi3WtaqJICgvfA" target="_blank" data-saferedirecturl="https://www.google.com/url?q=https://documents.service.gov.uk/d/f8FKyAk4SCeu4_sjf5zV5w/p0-ZUPWESuGUsbUdomOoHQ?key%3DVvieEVMIEWUZTKZQWPR4Lb4HWCeCwVi3WtaqJICgvfA&amp;source=gmail&amp;ust=1632034513216000&amp;usg=AFQjCNG4im8mu2Nu231SXyHMi3gptqaYaQ">https://documents.service.gov.<wbr>uk/d/f8FKyAk4SCeu4_sjf5zV5w/<wbr>p0-ZUPWESuGUsbUdomOoHQ?key=<wbr>VvieEVMIEWUZTKZQWPR4Lb4HWCeCwV<wbr>i3WtaqJICgvfA</a></p>
12
+ <hr style="border:0;height:1px;background:#bfc1c3;Margin:30px 0 30px 0">
13
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Additional Information File</p>
14
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">no additional file</p>
15
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">no additional file</p>
16
+ <hr style="border:0;height:1px;background:#bfc1c3;Margin:30px 0 30px 0">
17
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Your feedback helps us improve this service:<br><a style="word-wrap:break-word;color:#005ea5" href="https://www.gov.uk/done/employment-tribunals-make-a-claim" target="_blank" data-saferedirecturl="https://www.google.com/url?q=https://www.gov.uk/done/employment-tribunals-make-a-claim&amp;source=gmail&amp;ust=1632034513216000&amp;usg=AFQjCNHY6ZdK3Y4wrMzZ6kpEubbSkN6byQ">https://www.gov.uk/done/<wbr>employment-tribunals-make-a-<wbr>claim</a></p>
18
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Help us keep track. Complete our diversity monitoring questionnaire.<br><a style="word-wrap:break-word;color:#005ea5" href="https://employmenttribunals.service.gov.uk/en/apply/diversity" target="_blank" data-saferedirecturl="https://www.google.com/url?q=https://employmenttribunals.service.gov.uk/en/apply/diversity&amp;source=gmail&amp;ust=1632034513216000&amp;usg=AFQjCNGBtP5C9AjOY9cl0HAKTJYjMna5BA">https://employmenttribunals.<wbr>service.gov.uk/en/apply/<wbr>diversity</a></p>
19
+ <p style="Margin:0 0 20px 0;font-size:19px;line-height:25px;color:#0b0c0c">Contact us: <a style="word-wrap:break-word;color:#005ea5" href="http://www.justice.gov.uk/contacts/hmcts/tribunals/employment" target="_blank" data-saferedirecturl="https://www.google.com/url?q=http://www.justice.gov.uk/contacts/hmcts/tribunals/employment&amp;source=gmail&amp;ust=1632034513216000&amp;usg=AFQjCNEq9IFj6UCn4aCCO1P8taYI_SQQRw">http://www.justice.gov.uk/<wbr>contacts/hmcts/tribunals/<wbr>employment</a></p>
@@ -0,0 +1,64 @@
1
+ <div style="font-family:Helvetica,Arial,sans-serif;font-size:16px;margin:0;color:#0b0c0c">
2
+ <table style="border-collapse:collapse;min-width:100%;width:100%!important" width="100%" cellspacing="0" cellpadding="0" border="0">
3
+ <tbody><tr>
4
+ <td width="100%" height="53" bgcolor="#0b0c0c">
5
+
6
+ <table style="border-collapse:collapse;max-width:580px" width="100%" cellspacing="0" cellpadding="0" border="0" align="center">
7
+ <tbody><tr>
8
+ <td width="70" valign="middle" bgcolor="#0b0c0c">
9
+ <a href="https://www.gov.uk" title="Go to the GOV.UK homepage" style="text-decoration:none" target="_blank" data-saferedirecturl="https://www.google.com/url?q=https://www.gov.uk&amp;source=gmail&amp;ust=1632034513216000&amp;usg=AFQjCNHCLGv04jJRG6wO0SmmxP6YUu3R_w">
10
+ <table style="border-collapse:collapse" cellspacing="0" cellpadding="0" border="0">
11
+ <tbody><tr>
12
+ <td style="padding-left:10px">
13
+ <img src="https://ci4.googleusercontent.com/proxy/pvN1p4x4E1j9aX5roof_HW0YpKqWW5iSOZzXLTlAyx0NPYGuqBupZFadY3FPEYjc00W_X_99tYW-5-3Y52Si7-xReAOZTsXAcfafeDRvFFZS_xQvOBKajCUR5L0fvA8=s0-d-e1-ft#https://static.notifications.service.gov.uk/images/gov.uk_logotype_crown.png" alt=" " style="Margin-top:4px" height="32" border="0" class="CToWUd">
14
+ </td>
15
+ <td style="font-size:28px;line-height:1.315789474;Margin-top:4px;padding-left:10px">
16
+ <span style="font-family:Helvetica,Arial,sans-serif;font-weight:700;color:#ffffff;text-decoration:none;vertical-align:top;display:inline-block">GOV.UK</span>
17
+ </td>
18
+ </tr>
19
+ </tbody></table>
20
+ </a>
21
+ </td>
22
+ </tr>
23
+ </tbody></table>
24
+
25
+ </td>
26
+ </tr>
27
+ </tbody></table>
28
+ <table style="border-collapse:collapse;max-width:580px;width:100%!important" width="100%" cellspacing="0" cellpadding="0" border="0" align="center">
29
+ <tbody><tr>
30
+ <td width="10" valign="middle" height="10"></td>
31
+ <td>
32
+
33
+ <table style="border-collapse:collapse" width="100%" cellspacing="0" cellpadding="0" border="0">
34
+ <tbody><tr>
35
+ <td width="100%" height="10" bgcolor="#005EA5"></td>
36
+ </tr>
37
+ </tbody></table>
38
+
39
+ </td>
40
+ <td width="10" valign="middle" height="10"></td>
41
+ </tr>
42
+ </tbody></table>
43
+
44
+
45
+
46
+ <table style="border-collapse:collapse;max-width:580px;width:100%!important" width="100%" cellspacing="0" cellpadding="0" border="0" align="center">
47
+ <tbody><tr>
48
+ <td height="30"><br></td>
49
+ </tr>
50
+ <tr>
51
+ <td width="10" valign="middle"><br></td>
52
+ <td style="font-family:Helvetica,Arial,sans-serif;font-size:19px;line-height:1.315789474;max-width:560px">
53
+
54
+ <%= yield %>
55
+
56
+ </td>
57
+ <td width="10" valign="middle"><br></td>
58
+ </tr>
59
+ <tr>
60
+ <td height="30"><br></td>
61
+ </tr>
62
+ </tbody></table><div class="yj6qo"></div><div class="adL">
63
+
64
+ </div></div>
metadata ADDED
@@ -0,0 +1,219 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: gov_fake_notify
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.1.1
5
+ platform: ruby
6
+ authors:
7
+ - garytaylor
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2021-09-28 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: activemodel
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 5.2.3
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: 5.2.3
27
+ - !ruby/object:Gem::Dependency
28
+ name: iodine
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '0.7'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '0.7'
41
+ - !ruby/object:Gem::Dependency
42
+ name: jwt
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '2.2'
48
+ - - ">="
49
+ - !ruby/object:Gem::Version
50
+ version: 2.2.3
51
+ type: :runtime
52
+ prerelease: false
53
+ version_requirements: !ruby/object:Gem::Requirement
54
+ requirements:
55
+ - - "~>"
56
+ - !ruby/object:Gem::Version
57
+ version: '2.2'
58
+ - - ">="
59
+ - !ruby/object:Gem::Version
60
+ version: 2.2.3
61
+ - !ruby/object:Gem::Dependency
62
+ name: mail
63
+ requirement: !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - "~>"
66
+ - !ruby/object:Gem::Version
67
+ version: '2.7'
68
+ - - ">="
69
+ - !ruby/object:Gem::Version
70
+ version: 2.7.1
71
+ type: :runtime
72
+ prerelease: false
73
+ version_requirements: !ruby/object:Gem::Requirement
74
+ requirements:
75
+ - - "~>"
76
+ - !ruby/object:Gem::Version
77
+ version: '2.7'
78
+ - - ">="
79
+ - !ruby/object:Gem::Version
80
+ version: 2.7.1
81
+ - !ruby/object:Gem::Dependency
82
+ name: roda
83
+ requirement: !ruby/object:Gem::Requirement
84
+ requirements:
85
+ - - "~>"
86
+ - !ruby/object:Gem::Version
87
+ version: '3.48'
88
+ type: :runtime
89
+ prerelease: false
90
+ version_requirements: !ruby/object:Gem::Requirement
91
+ requirements:
92
+ - - "~>"
93
+ - !ruby/object:Gem::Version
94
+ version: '3.48'
95
+ - !ruby/object:Gem::Dependency
96
+ name: tilt
97
+ requirement: !ruby/object:Gem::Requirement
98
+ requirements:
99
+ - - "~>"
100
+ - !ruby/object:Gem::Version
101
+ version: '2.0'
102
+ - - ">="
103
+ - !ruby/object:Gem::Version
104
+ version: 2.0.10
105
+ type: :runtime
106
+ prerelease: false
107
+ version_requirements: !ruby/object:Gem::Requirement
108
+ requirements:
109
+ - - "~>"
110
+ - !ruby/object:Gem::Version
111
+ version: '2.0'
112
+ - - ">="
113
+ - !ruby/object:Gem::Version
114
+ version: 2.0.10
115
+ - !ruby/object:Gem::Dependency
116
+ name: thor
117
+ requirement: !ruby/object:Gem::Requirement
118
+ requirements:
119
+ - - "~>"
120
+ - !ruby/object:Gem::Version
121
+ version: '1.1'
122
+ type: :runtime
123
+ prerelease: false
124
+ version_requirements: !ruby/object:Gem::Requirement
125
+ requirements:
126
+ - - "~>"
127
+ - !ruby/object:Gem::Version
128
+ version: '1.1'
129
+ - !ruby/object:Gem::Dependency
130
+ name: rubocop
131
+ requirement: !ruby/object:Gem::Requirement
132
+ requirements:
133
+ - - "~>"
134
+ - !ruby/object:Gem::Version
135
+ version: '1.21'
136
+ type: :development
137
+ prerelease: false
138
+ version_requirements: !ruby/object:Gem::Requirement
139
+ requirements:
140
+ - - "~>"
141
+ - !ruby/object:Gem::Version
142
+ version: '1.21'
143
+ description: A fake govuk notify service that sends emails via smtp for ease of testing
144
+ email:
145
+ - gary.taylor@hismessages.com
146
+ executables:
147
+ - gov_fake_notify
148
+ extensions: []
149
+ extra_rdoc_files: []
150
+ files:
151
+ - ".gitignore"
152
+ - ".rspec"
153
+ - ".rubocop.yml"
154
+ - ".rubocop_todo.yml"
155
+ - ".ruby-version"
156
+ - ".travis.yml"
157
+ - Gemfile
158
+ - Gemfile.lock
159
+ - LICENSE.txt
160
+ - README.md
161
+ - Rakefile
162
+ - bin/console
163
+ - bin/setup
164
+ - exe/gov_fake_notify
165
+ - gov_fake_notify.gemspec
166
+ - lib/gov_fake_notify.rb
167
+ - lib/gov_fake_notify/attachment_store.rb
168
+ - lib/gov_fake_notify/cli.rb
169
+ - lib/gov_fake_notify/cli/root.rb
170
+ - lib/gov_fake_notify/commands/create_template_command.rb
171
+ - lib/gov_fake_notify/commands/fetch_all_messages_status_command.rb
172
+ - lib/gov_fake_notify/commands/fetch_file_command.rb
173
+ - lib/gov_fake_notify/commands/fetch_message_status_command.rb
174
+ - lib/gov_fake_notify/commands/fetch_templates_command.rb
175
+ - lib/gov_fake_notify/commands/send_email_command.rb
176
+ - lib/gov_fake_notify/config.rb
177
+ - lib/gov_fake_notify/control_app.rb
178
+ - lib/gov_fake_notify/current_service.rb
179
+ - lib/gov_fake_notify/files_app.rb
180
+ - lib/gov_fake_notify/iodine.rb
181
+ - lib/gov_fake_notify/notifications_app.rb
182
+ - lib/gov_fake_notify/root_app.rb
183
+ - lib/gov_fake_notify/store.rb
184
+ - lib/gov_fake_notify/templates_app.rb
185
+ - lib/gov_fake_notify/version.rb
186
+ - lib/views/files/confirm.html.erb
187
+ - lib/views/files/download.html.erb
188
+ - lib/views/govuk/file.html.erb
189
+ - lib/views/govuk/horizontal_line.html.erb
190
+ - lib/views/govuk/paragraph.html.erb
191
+ - lib/views/govuk/show.html.erb
192
+ - lib/views/layouts/govuk.html.erb
193
+ homepage: https://github.com/hmcts/gov_fake_notify
194
+ licenses:
195
+ - MIT
196
+ metadata:
197
+ homepage_uri: https://github.com/hmcts/gov_fake_notify
198
+ source_code_uri: https://github.com/hmcts/gov_fake_notify
199
+ changelog_uri: https://github.com/hmcts/gov_fake_notify/changelog.md
200
+ post_install_message:
201
+ rdoc_options: []
202
+ require_paths:
203
+ - lib
204
+ required_ruby_version: !ruby/object:Gem::Requirement
205
+ requirements:
206
+ - - ">="
207
+ - !ruby/object:Gem::Version
208
+ version: 2.5.0
209
+ required_rubygems_version: !ruby/object:Gem::Requirement
210
+ requirements:
211
+ - - ">="
212
+ - !ruby/object:Gem::Version
213
+ version: '0'
214
+ requirements: []
215
+ rubygems_version: 3.1.6
216
+ signing_key:
217
+ specification_version: 4
218
+ summary: A fake govuk notify service
219
+ test_files: []