Skip to content

Commit 42524a5

Browse files
authored
chore: Move dev dependencies to gemspec (#11)
1 parent 5825c20 commit 42524a5

File tree

5 files changed

+19
-18
lines changed

5 files changed

+19
-18
lines changed

.rubocop.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
require:
1+
plugins:
22
- rubocop-performance
33
- rubocop-rake
44
- rubocop-rspec
@@ -291,7 +291,7 @@ Style/PerlBackrefs:
291291
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#no-perl-regexp-last-matchers'
292292
Enabled: false
293293

294-
Naming/PredicateName:
294+
Naming/PredicatePrefix:
295295
Description: 'Check the names of predicate methods.'
296296
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#bool-methods-qmark'
297297
ForbiddenPrefixes:
@@ -890,8 +890,11 @@ Style/WhileUntilDo:
890890
Style/ZeroLengthPredicate:
891891
Enabled: false
892892

893-
RSpec/FilePath:
894-
SpecSuffixOnly: true
893+
RSpec/SpecFilePathFormat:
894+
Enabled: false
895+
896+
RSpec/SpecFilePathSuffix:
897+
Enabled: true
895898

896899
RSpec/ExampleLength:
897900
Enabled: false

Gemfile

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,3 @@ source "https://rubygems.org"
44

55
# Specify your gem's dependencies in launchdarkly-server-sdk-otel.gemspec
66
gemspec
7-
8-
gem "rake", "~> 13.0"
9-
10-
gem "rspec", "~> 3.0"
11-
12-
gem "rubocop", "~> 1.21"
13-
gem "rubocop-performance", "~> 1.15"
14-
gem "rubocop-rake", "~> 0.6"
15-
gem "rubocop-rspec", "~> 2.27"

launchdarkly-server-sdk-otel.gemspec

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,13 @@ Gem::Specification.new do |spec|
3131
spec.add_runtime_dependency "launchdarkly-server-sdk", "~> 8.4.0"
3232
spec.add_runtime_dependency "opentelemetry-sdk", "~> 1.4.0"
3333

34+
spec.add_development_dependency 'rake', '~> 13.0'
35+
spec.add_development_dependency 'rspec', '~> 3.0'
36+
spec.add_development_dependency 'rubocop', '~> 1.21'
37+
spec.add_development_dependency 'rubocop-performance', '~> 1.15'
38+
spec.add_development_dependency 'rubocop-rake', '~> 0.6'
39+
spec.add_development_dependency 'rubocop-rspec', '~> 3.6'
40+
3441
# For more information and examples about making a new gem, check out our
3542
# guide at: https://bundler.io/guides/creating_gem.html
3643
end

spec/ldclient_otel_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22

33
RSpec.describe LaunchDarkly::Otel do
44
it 'has a version number' do
5-
expect(LaunchDarkly::Otel::VERSION).not_to be nil
5+
expect(LaunchDarkly::Otel::VERSION).not_to be_nil
66
end
77
end

spec/tracing_hook_spec.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
expect(event.attributes['feature_flag.key']).to eq 'boolean'
4343
expect(event.attributes['feature_flag.provider_name']).to eq 'LaunchDarkly'
4444
expect(event.attributes['feature_flag.context.key']).to eq 'org:org-key'
45-
expect(event.attributes['feature_flag.variant']).to eq nil
45+
expect(event.attributes['feature_flag.variant']).to be_nil
4646
end
4747
end
4848

@@ -109,7 +109,7 @@
109109
expect(event.attributes['feature_flag.key']).to eq 'boolean'
110110
expect(event.attributes['feature_flag.provider_name']).to eq 'LaunchDarkly'
111111
expect(event.attributes['feature_flag.context.key']).to eq 'org:org-key'
112-
expect(event.attributes['feature_flag.variant']).to eq nil
112+
expect(event.attributes['feature_flag.variant']).to be_nil
113113
end
114114

115115
it 'hook makes its span active' do
@@ -140,13 +140,13 @@
140140
expect(middle.events[0].attributes['feature_flag.key']).to eq 'boolean'
141141
expect(middle.events[0].attributes['feature_flag.provider_name']).to eq 'LaunchDarkly'
142142
expect(middle.events[0].attributes['feature_flag.context.key']).to eq 'org:org-key'
143-
expect(middle.events[0].attributes['feature_flag.variant']).to eq nil
143+
expect(middle.events[0].attributes['feature_flag.variant']).to be_nil
144144

145145
expect(top.events[0].name).to eq 'feature_flag'
146146
expect(top.events[0].attributes['feature_flag.key']).to eq 'boolean'
147147
expect(top.events[0].attributes['feature_flag.provider_name']).to eq 'LaunchDarkly'
148148
expect(top.events[0].attributes['feature_flag.context.key']).to eq 'org:org-key'
149-
expect(top.events[0].attributes['feature_flag.variant']).to eq nil
149+
expect(top.events[0].attributes['feature_flag.variant']).to be_nil
150150
end
151151
end
152152
end

0 commit comments

Comments
 (0)