pheme 4.0.15 → 5.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/main.yml +22 -2
- data/.github/workflows/stale.yml +20 -0
- data/.ruby-version +1 -1
- data/CHANGELOG.md +16 -0
- data/Gemfile.lock +34 -36
- data/Rakefile +3 -1
- data/lib/pheme/message_type/aws_event.rb +1 -1
- data/lib/pheme/queue_poller.rb +2 -2
- data/lib/pheme/version.rb +1 -1
- data/lib/pheme.rb +1 -1
- data/pheme.gemspec +12 -12
- data/spec/message_handler_spec.rb +1 -1
- data/spec/message_type/aws_event_spec.rb +2 -1
- data/spec/message_type/sns_message_spec.rb +1 -1
- data/spec/queue_poller_spec.rb +12 -12
- data/spec/version_spec.rb +1 -2
- metadata +6 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 73d6d18c98b810a214ef5386e5ec140fc32def55ab066649e7ff4d1296dda78b
|
4
|
+
data.tar.gz: b8735d499447d6e83a3a5b301a42b58832dd814e7551be5a2b30b2fc9ee58cd7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7df69644e5d8a98420f716f7435197f6d303d1db53a74b98e50f26a93a8c0e3de54f33a6421bd1169948d63fbad5542dd33e7c1251e4f0167ce6f0d9095342a3
|
7
|
+
data.tar.gz: c48888c79ea780c30b07bdbd7135f424b9ce306deb7839fc8146a3805a9046aed318be03d94ef472585eb496a101a6f47c7ca5f79916f27fdd0a6e624c7e63be
|
data/.github/workflows/main.yml
CHANGED
@@ -10,19 +10,39 @@ jobs:
|
|
10
10
|
build:
|
11
11
|
name: Build
|
12
12
|
runs-on: ubuntu-20.04
|
13
|
+
strategy:
|
14
|
+
matrix:
|
15
|
+
ruby-version: [2.7.5, 3.0.3, 3.1.0]
|
13
16
|
steps:
|
14
17
|
- uses: actions/checkout@v2
|
15
18
|
with:
|
16
19
|
fetch-depth: 0
|
17
|
-
-
|
20
|
+
- name: Set up Ruby ${{ matrix.ruby-version }}
|
21
|
+
uses: ruby/setup-ruby@v1
|
18
22
|
with:
|
19
23
|
bundler-cache: true
|
24
|
+
ruby-version: ${{ matrix.ruby-version }}
|
20
25
|
- name: Lint
|
21
26
|
run: bundle exec rubocop
|
22
27
|
- name: Test
|
23
28
|
run: bundle exec rspec
|
29
|
+
|
30
|
+
# Separate `release` job from `build`, as we only want release to be run once
|
31
|
+
# and not run for each ruby version in the matrix:
|
32
|
+
release:
|
33
|
+
name: Release
|
34
|
+
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master'
|
35
|
+
needs: build
|
36
|
+
runs-on: ubuntu-20.04
|
37
|
+
steps:
|
38
|
+
- uses: actions/checkout@v2
|
39
|
+
with:
|
40
|
+
fetch-depth: 0
|
41
|
+
- name: Set up Ruby
|
42
|
+
uses: ruby/setup-ruby@v1
|
43
|
+
with:
|
44
|
+
bundler-cache: true
|
24
45
|
- name: Release the gem
|
25
|
-
if: ${{ github.ref == 'refs/heads/main' }}
|
26
46
|
run: |
|
27
47
|
mkdir -p ~/.gem
|
28
48
|
cat << EOF > ~/.gem/credentials
|
@@ -0,0 +1,20 @@
|
|
1
|
+
name: 'Close stale PRs'
|
2
|
+
on:
|
3
|
+
schedule:
|
4
|
+
- cron: '30 6 * * *' # 6:30 am UTC: 1:30 am EST
|
5
|
+
|
6
|
+
jobs:
|
7
|
+
stale:
|
8
|
+
runs-on: ubuntu-latest
|
9
|
+
steps:
|
10
|
+
- uses: actions/stale@v4
|
11
|
+
with:
|
12
|
+
days-before-stale: 30
|
13
|
+
days-before-close: 60
|
14
|
+
stale-pr-message: >
|
15
|
+
This issue has been automatically marked as stale because it has not had
|
16
|
+
recent activity. It will be closed if no further activity occurs.
|
17
|
+
close-pr-message: >
|
18
|
+
This issue has been automatically closed because it has had no activity
|
19
|
+
for over 90 days. Please re-open if you feel this was done in error.
|
20
|
+
exempt-pr-labels: 'dependabot,depfu,dependencies,security'
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.7.
|
1
|
+
2.7.5
|
data/CHANGELOG.md
CHANGED
@@ -4,6 +4,22 @@ All notable changes to this project will be documented in this file.
|
|
4
4
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
5
5
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
6
6
|
|
7
|
+
## 5.0.1 - 2022-02-02
|
8
|
+
### Changed
|
9
|
+
- Updated dependencies
|
10
|
+
|
11
|
+
## 5.0.0 - 2022-01-04
|
12
|
+
### Changed
|
13
|
+
- Remove RecusiveOpenStruct in favor of ResourceStruct::FlexStruct
|
14
|
+
|
15
|
+
## 4.1.1 - 2022-01-04
|
16
|
+
### Changed
|
17
|
+
- Updated dependencies
|
18
|
+
|
19
|
+
## 4.1.0 - 2021-12-31
|
20
|
+
### Changed
|
21
|
+
- Add Ruby 3 support
|
22
|
+
|
7
23
|
## 4.0.15 - 2021-12-03
|
8
24
|
### Changed
|
9
25
|
- Updated dependencies
|
data/Gemfile.lock
CHANGED
@@ -1,35 +1,34 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
pheme (
|
4
|
+
pheme (5.0.1)
|
5
5
|
activesupport (>= 4)
|
6
6
|
aws-sdk-sns (~> 1.1)
|
7
7
|
aws-sdk-sqs (~> 1.3)
|
8
|
-
|
8
|
+
resource-struct (~> 0.4)
|
9
9
|
smarter_csv (~> 1)
|
10
10
|
|
11
11
|
GEM
|
12
12
|
remote: https://rubygems.org/
|
13
13
|
specs:
|
14
|
-
activesupport (
|
14
|
+
activesupport (7.0.1)
|
15
15
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
16
16
|
i18n (>= 1.6, < 2)
|
17
17
|
minitest (>= 5.1)
|
18
18
|
tzinfo (~> 2.0)
|
19
|
-
zeitwerk (~> 2.3)
|
20
19
|
ast (2.4.2)
|
21
20
|
aws-eventstream (1.2.0)
|
22
|
-
aws-partitions (1.
|
23
|
-
aws-sdk-core (3.
|
21
|
+
aws-partitions (1.551.0)
|
22
|
+
aws-sdk-core (3.125.5)
|
24
23
|
aws-eventstream (~> 1, >= 1.0.2)
|
25
24
|
aws-partitions (~> 1, >= 1.525.0)
|
26
25
|
aws-sigv4 (~> 1.1)
|
27
26
|
jmespath (~> 1.0)
|
28
|
-
aws-sdk-sns (1.
|
29
|
-
aws-sdk-core (~> 3, >= 3.
|
27
|
+
aws-sdk-sns (1.50.0)
|
28
|
+
aws-sdk-core (~> 3, >= 3.125.0)
|
30
29
|
aws-sigv4 (~> 1.1)
|
31
|
-
aws-sdk-sqs (1.
|
32
|
-
aws-sdk-core (~> 3, >= 3.
|
30
|
+
aws-sdk-sqs (1.49.0)
|
31
|
+
aws-sdk-core (~> 3, >= 3.125.0)
|
33
32
|
aws-sigv4 (~> 1.1)
|
34
33
|
aws-sigv4 (1.4.0)
|
35
34
|
aws-eventstream (~> 1, >= 1.0.2)
|
@@ -37,23 +36,23 @@ GEM
|
|
37
36
|
bundler (>= 1.2.0, < 3)
|
38
37
|
thor (~> 1.0)
|
39
38
|
concurrent-ruby (1.1.9)
|
40
|
-
diff-lcs (1.
|
39
|
+
diff-lcs (1.5.0)
|
41
40
|
docile (1.4.0)
|
42
|
-
git (1.
|
41
|
+
git (1.10.2)
|
43
42
|
rchardet (~> 1.8)
|
44
|
-
i18n (1.
|
43
|
+
i18n (1.9.1)
|
45
44
|
concurrent-ruby (~> 1.0)
|
46
|
-
jmespath (1.
|
47
|
-
minitest (5.
|
45
|
+
jmespath (1.5.0)
|
46
|
+
minitest (5.15.0)
|
48
47
|
parallel (1.21.0)
|
49
|
-
parser (3.0.
|
48
|
+
parser (3.1.0.0)
|
50
49
|
ast (~> 2.4.1)
|
51
50
|
rack (2.2.3)
|
52
|
-
rainbow (3.
|
51
|
+
rainbow (3.1.1)
|
53
52
|
rake (13.0.6)
|
54
53
|
rchardet (1.8.0)
|
55
|
-
|
56
|
-
|
54
|
+
regexp_parser (2.2.0)
|
55
|
+
resource-struct (0.4.0)
|
57
56
|
rexml (3.2.5)
|
58
57
|
rspec (3.10.0)
|
59
58
|
rspec-core (~> 3.10.0)
|
@@ -61,41 +60,41 @@ GEM
|
|
61
60
|
rspec-mocks (~> 3.10.0)
|
62
61
|
rspec-collection_matchers (1.2.0)
|
63
62
|
rspec-expectations (>= 2.99.0.beta1)
|
64
|
-
rspec-core (3.10.
|
63
|
+
rspec-core (3.10.2)
|
65
64
|
rspec-support (~> 3.10.0)
|
66
|
-
rspec-expectations (3.10.
|
65
|
+
rspec-expectations (3.10.2)
|
67
66
|
diff-lcs (>= 1.2.0, < 2.0)
|
68
67
|
rspec-support (~> 3.10.0)
|
69
68
|
rspec-its (1.3.0)
|
70
69
|
rspec-core (>= 3.0.0)
|
71
70
|
rspec-expectations (>= 3.0.0)
|
72
|
-
rspec-mocks (3.10.
|
71
|
+
rspec-mocks (3.10.3)
|
73
72
|
diff-lcs (>= 1.2.0, < 2.0)
|
74
73
|
rspec-support (~> 3.10.0)
|
75
74
|
rspec-support (3.10.3)
|
76
|
-
rspec_junit_formatter (0.
|
75
|
+
rspec_junit_formatter (0.5.1)
|
77
76
|
rspec-core (>= 2, < 4, != 2.12.0)
|
78
|
-
rubocop (1.
|
77
|
+
rubocop (1.25.0)
|
79
78
|
parallel (~> 1.10)
|
80
|
-
parser (>= 3.
|
79
|
+
parser (>= 3.1.0.0)
|
81
80
|
rainbow (>= 2.2.2, < 4.0)
|
82
81
|
regexp_parser (>= 1.8, < 3.0)
|
83
82
|
rexml
|
84
|
-
rubocop-ast (>= 1.
|
83
|
+
rubocop-ast (>= 1.15.1, < 2.0)
|
85
84
|
ruby-progressbar (~> 1.7)
|
86
85
|
unicode-display_width (>= 1.4.0, < 3.0)
|
87
|
-
rubocop-ast (1.
|
86
|
+
rubocop-ast (1.15.1)
|
88
87
|
parser (>= 3.0.1.1)
|
89
|
-
rubocop-performance (1.
|
88
|
+
rubocop-performance (1.13.2)
|
90
89
|
rubocop (>= 1.7.0, < 2.0)
|
91
90
|
rubocop-ast (>= 0.4.0)
|
92
|
-
rubocop-rails (2.
|
91
|
+
rubocop-rails (2.13.2)
|
93
92
|
activesupport (>= 4.2.0)
|
94
93
|
rack (>= 1.1)
|
95
94
|
rubocop (>= 1.7.0, < 2.0)
|
96
|
-
rubocop-rspec (2.
|
95
|
+
rubocop-rspec (2.8.0)
|
97
96
|
rubocop (~> 1.19)
|
98
|
-
rubocop-vendor (0.
|
97
|
+
rubocop-vendor (0.8.0)
|
99
98
|
rubocop (>= 0.53.0)
|
100
99
|
ruby-progressbar (1.11.0)
|
101
100
|
simplecov (0.21.2)
|
@@ -105,17 +104,16 @@ GEM
|
|
105
104
|
simplecov-html (0.12.3)
|
106
105
|
simplecov_json_formatter (0.1.3)
|
107
106
|
smarter_csv (1.2.9)
|
108
|
-
thor (1.1
|
107
|
+
thor (1.2.1)
|
109
108
|
tzinfo (2.0.4)
|
110
109
|
concurrent-ruby (~> 1.0)
|
111
110
|
unicode-display_width (2.1.0)
|
112
|
-
ws-style (6.
|
113
|
-
rubocop (>= 1.
|
111
|
+
ws-style (6.13.6)
|
112
|
+
rubocop (>= 1.23)
|
114
113
|
rubocop-performance (>= 1.10.2)
|
115
114
|
rubocop-rails (>= 2.9.1)
|
116
115
|
rubocop-rspec (>= 2.2.0)
|
117
116
|
rubocop-vendor (>= 0.6.0)
|
118
|
-
zeitwerk (2.5.1)
|
119
117
|
|
120
118
|
PLATFORMS
|
121
119
|
ruby
|
@@ -134,4 +132,4 @@ DEPENDENCIES
|
|
134
132
|
ws-style
|
135
133
|
|
136
134
|
BUNDLED WITH
|
137
|
-
2.2.
|
135
|
+
2.2.33
|
data/Rakefile
CHANGED
data/lib/pheme/queue_poller.rb
CHANGED
@@ -127,12 +127,12 @@ module Pheme
|
|
127
127
|
|
128
128
|
def parse_csv(message_contents)
|
129
129
|
parsed_body = SmarterCSV.process(StringIO.new(message_contents))
|
130
|
-
parsed_body.map { |item|
|
130
|
+
parsed_body.map { |item| ResourceStruct::FlexStruct.new(item) }
|
131
131
|
end
|
132
132
|
|
133
133
|
def parse_json(message_contents)
|
134
134
|
parsed_body = JSON.parse(message_contents)
|
135
|
-
|
135
|
+
ResourceStruct::FlexStruct.new({ wrapper: parsed_body }).wrapper
|
136
136
|
end
|
137
137
|
|
138
138
|
def handle(message, metadata, message_attributes)
|
data/lib/pheme/version.rb
CHANGED
data/lib/pheme.rb
CHANGED
data/pheme.gemspec
CHANGED
@@ -1,32 +1,32 @@
|
|
1
1
|
lib = File.expand_path('lib', __dir__)
|
2
2
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
3
3
|
|
4
|
-
require
|
4
|
+
require 'pheme/version'
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
raise 'RubyGems 2.0 or newer is required to protect against public gem pushes.' unless s.respond_to?(:metadata)
|
8
8
|
|
9
|
-
s.name =
|
9
|
+
s.name = 'pheme'
|
10
10
|
s.version = Pheme::VERSION
|
11
|
-
s.authors = [
|
12
|
-
s.email = [
|
11
|
+
s.authors = ['Peter Graham']
|
12
|
+
s.email = ['peter@wealthsimple.com']
|
13
13
|
s.description = 'Ruby AWS SNS publisher + SQS poller & message handler'
|
14
14
|
s.summary = 'Ruby SNS publisher + SQS poller & message handler'
|
15
|
-
s.homepage =
|
15
|
+
s.homepage = 'https://github.com/wealthsimple/pheme'
|
16
16
|
|
17
17
|
s.files = `git ls-files`.split($INPUT_RECORD_SEPARATOR)
|
18
18
|
s.executables = s.files.grep(%r{^bin/}).map { |f| File.basename(f) }
|
19
19
|
s.test_files = s.files.grep(%r{^(test|spec|features)/})
|
20
|
-
s.require_paths = [
|
21
|
-
s.license =
|
20
|
+
s.require_paths = ['lib']
|
21
|
+
s.license = 'MIT'
|
22
22
|
|
23
23
|
s.required_ruby_version = '>= 2.7.3'
|
24
24
|
|
25
|
-
s.add_dependency
|
26
|
-
s.add_dependency
|
27
|
-
s.add_dependency
|
28
|
-
s.add_dependency
|
29
|
-
s.add_dependency
|
25
|
+
s.add_dependency 'activesupport', '>= 4'
|
26
|
+
s.add_dependency 'aws-sdk-sns', '~> 1.1'
|
27
|
+
s.add_dependency 'aws-sdk-sqs', '~> 1.3'
|
28
|
+
s.add_dependency 'resource-struct', '~> 0.4'
|
29
|
+
s.add_dependency 'smarter_csv', '~> 1'
|
30
30
|
|
31
31
|
s.add_development_dependency 'bundler'
|
32
32
|
s.add_development_dependency 'git'
|
@@ -3,7 +3,7 @@ describe Pheme::MessageHandler do
|
|
3
3
|
|
4
4
|
before { use_default_configuration! }
|
5
5
|
|
6
|
-
let(:message) {
|
6
|
+
let(:message) { ResourceStruct::FlexStruct.new(status: status) }
|
7
7
|
let(:timestamp) { '2018-04-17T21:45:05.915Z' }
|
8
8
|
|
9
9
|
describe "#handle" do
|
@@ -3,7 +3,8 @@ describe Pheme::MessageType::AwsEvent do
|
|
3
3
|
let(:message_id) { SecureRandom.uuid }
|
4
4
|
let(:queue_url) { 'http://queue_url' }
|
5
5
|
let(:queue_message) do
|
6
|
-
|
6
|
+
instance_double(
|
7
|
+
Aws::SQS::Message,
|
7
8
|
message_id: message_id,
|
8
9
|
body: { 'Records' => records }.to_json,
|
9
10
|
queue_url: queue_url,
|
@@ -22,7 +22,7 @@ describe Pheme::MessageType::SnsMessage do
|
|
22
22
|
|
23
23
|
describe "#parse_message" do
|
24
24
|
context "with JSON message" do
|
25
|
-
let!(:message) {
|
25
|
+
let!(:message) { ResourceStruct::FlexStruct.new({ body: '{"Message":"{\"test\":\"test\"}"}' }) }
|
26
26
|
|
27
27
|
it 'parses the message correctly' do
|
28
28
|
expect(subject.parse_body(message).test).to eq("test")
|
data/spec/queue_poller_spec.rb
CHANGED
@@ -5,7 +5,7 @@ describe Pheme::QueuePoller do
|
|
5
5
|
let(:topic_arn) { 'arn:topic:test' }
|
6
6
|
|
7
7
|
let!(:queue_message) do
|
8
|
-
|
8
|
+
ResourceStruct::FlexStruct.new(
|
9
9
|
body: { Message: message }.to_json,
|
10
10
|
message_id: message_id,
|
11
11
|
)
|
@@ -57,7 +57,7 @@ describe Pheme::QueuePoller do
|
|
57
57
|
|
58
58
|
before do
|
59
59
|
allow(Aws::SQS::QueuePoller).to receive(:new).and_return(aws_poller)
|
60
|
-
allow(aws_poller).to receive(:before_request).and_yield(
|
60
|
+
allow(aws_poller).to receive(:before_request).and_yield(ResourceStruct::FlexStruct.new(received_message_count: max_messages))
|
61
61
|
end
|
62
62
|
|
63
63
|
it 'throws error' do
|
@@ -145,7 +145,7 @@ describe Pheme::QueuePoller do
|
|
145
145
|
|
146
146
|
context 'when message attributes' do
|
147
147
|
let(:queue_message) do
|
148
|
-
|
148
|
+
ResourceStruct::FlexStruct.new(
|
149
149
|
body: {
|
150
150
|
Message: message,
|
151
151
|
MessageAttributes: {
|
@@ -222,7 +222,7 @@ describe Pheme::QueuePoller do
|
|
222
222
|
end
|
223
223
|
|
224
224
|
it { is_expected.to have(2).items }
|
225
|
-
it { is_expected.to eq(
|
225
|
+
it { is_expected.to eq(ResourceStruct::FlexStruct.new({ wrapper: expected_message }).wrapper) }
|
226
226
|
end
|
227
227
|
|
228
228
|
context "with unknown message format" do
|
@@ -240,7 +240,7 @@ describe Pheme::QueuePoller do
|
|
240
240
|
|
241
241
|
it { is_expected.to be_a(Array) }
|
242
242
|
its(:first) { is_expected.to be_a(Array) }
|
243
|
-
its('first.first') { is_expected.to be_a(
|
243
|
+
its('first.first') { is_expected.to be_a(ResourceStruct::FlexStruct) }
|
244
244
|
|
245
245
|
it "parses the nested object" do
|
246
246
|
expect(subject.first.first.test).to eq('test')
|
@@ -284,7 +284,7 @@ describe Pheme::QueuePoller do
|
|
284
284
|
}
|
285
285
|
}
|
286
286
|
let!(:queue_message) do
|
287
|
-
|
287
|
+
ResourceStruct::FlexStruct.new(
|
288
288
|
body: notification.to_json,
|
289
289
|
message_id: message_id,
|
290
290
|
)
|
@@ -317,7 +317,7 @@ describe Pheme::QueuePoller do
|
|
317
317
|
}
|
318
318
|
}
|
319
319
|
let!(:queue_message) do
|
320
|
-
|
320
|
+
ResourceStruct::FlexStruct.new(
|
321
321
|
body: notification.to_json,
|
322
322
|
message_id: message_id,
|
323
323
|
)
|
@@ -348,7 +348,7 @@ describe Pheme::QueuePoller do
|
|
348
348
|
}
|
349
349
|
end
|
350
350
|
let!(:queue_message) do
|
351
|
-
|
351
|
+
ResourceStruct::FlexStruct.new(
|
352
352
|
body: notification.to_json,
|
353
353
|
message_id: message_id,
|
354
354
|
)
|
@@ -361,7 +361,7 @@ describe Pheme::QueuePoller do
|
|
361
361
|
|
362
362
|
it "handles the message" do
|
363
363
|
expect(ExampleMessageHandler).to receive(:new).with(
|
364
|
-
message:
|
364
|
+
message: ResourceStruct::FlexStruct.new(message),
|
365
365
|
metadata: { timestamp: timestamp, topic_arn: topic_arn },
|
366
366
|
message_attributes: {},
|
367
367
|
)
|
@@ -387,7 +387,7 @@ describe Pheme::QueuePoller do
|
|
387
387
|
}
|
388
388
|
end
|
389
389
|
let!(:queue_message) do
|
390
|
-
|
390
|
+
ResourceStruct::FlexStruct.new(
|
391
391
|
body: notification.to_json,
|
392
392
|
message_id: message_id,
|
393
393
|
)
|
@@ -416,7 +416,7 @@ describe Pheme::QueuePoller do
|
|
416
416
|
context "AWS-event message" do
|
417
417
|
subject { ExampleAwsEventQueuePoller.new(queue_url: queue_url) }
|
418
418
|
|
419
|
-
let(:queue_message) {
|
419
|
+
let(:queue_message) { ResourceStruct::FlexStruct.new(body: { 'Records' => records }.to_json) }
|
420
420
|
let(:records) do
|
421
421
|
[{ 'eventVersion' => '2.0', eventSource: 'aws:s3' }]
|
422
422
|
end
|
@@ -437,7 +437,7 @@ describe Pheme::QueuePoller do
|
|
437
437
|
let(:message) { { status: 'complete' } }
|
438
438
|
let(:notification) { { 'MessageId' => SecureRandom.uuid, 'Message' => message.to_json, 'Type' => 'Notification', 'Timestamp' => timestamp } }
|
439
439
|
let!(:queue_message) do
|
440
|
-
|
440
|
+
ResourceStruct::FlexStruct.new(
|
441
441
|
body: notification.to_json,
|
442
442
|
message_id: message_id,
|
443
443
|
)
|
data/spec/version_spec.rb
CHANGED
@@ -4,8 +4,7 @@ describe Pheme do
|
|
4
4
|
def get_version(git, branch = 'HEAD')
|
5
5
|
git.grep('VERSION = ', 'lib/*/version.rb', { object: branch }).
|
6
6
|
map { |_sha, matches| matches.first[1] }.
|
7
|
-
|
8
|
-
reject(&:nil?).
|
7
|
+
filter_map { |version_string| parse_version(version_string) }.
|
9
8
|
first
|
10
9
|
end
|
11
10
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pheme
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 5.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peter Graham
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-02-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -53,19 +53,19 @@ dependencies:
|
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '1.3'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name:
|
56
|
+
name: resource-struct
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: '
|
61
|
+
version: '0.4'
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '
|
68
|
+
version: '0.4'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: smarter_csv
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -216,6 +216,7 @@ files:
|
|
216
216
|
- ".github/CODEOWNERS"
|
217
217
|
- ".github/PULL_REQUEST_TEMPLATE.md"
|
218
218
|
- ".github/workflows/main.yml"
|
219
|
+
- ".github/workflows/stale.yml"
|
219
220
|
- ".gitignore"
|
220
221
|
- ".rspec"
|
221
222
|
- ".rubocop.yml"
|