File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7373 crack (0.4.3 )
7474 safe_yaml (~> 1.0.0 )
7575 crass (1.0.6 )
76- diff-lcs (1.3 )
76+ diff-lcs (1.4.4 )
7777 docile (1.3.2 )
7878 dry-configurable (0.11.6 )
7979 concurrent-ruby (~> 1.0 )
@@ -207,19 +207,19 @@ GEM
207207 rake (>= 0.8.7 )
208208 thor (>= 0.20.3 , < 2.0 )
209209 rake (13.0.1 )
210- rspec (3.8 .0 )
211- rspec-core (~> 3.8 .0 )
212- rspec-expectations (~> 3.8 .0 )
213- rspec-mocks (~> 3.8 .0 )
214- rspec-core (3.8 .2 )
215- rspec-support (~> 3.8.0 )
216- rspec-expectations (3.8.4 )
210+ rspec (3.9 .0 )
211+ rspec-core (~> 3.9 .0 )
212+ rspec-expectations (~> 3.9 .0 )
213+ rspec-mocks (~> 3.9 .0 )
214+ rspec-core (3.9 .2 )
215+ rspec-support (~> 3.9.3 )
216+ rspec-expectations (3.9.2 )
217217 diff-lcs (>= 1.2.0 , < 2.0 )
218- rspec-support (~> 3.8 .0 )
219- rspec-mocks (3.8 .1 )
218+ rspec-support (~> 3.9 .0 )
219+ rspec-mocks (3.9 .1 )
220220 diff-lcs (>= 1.2.0 , < 2.0 )
221- rspec-support (~> 3.8 .0 )
222- rspec-support (3.8.2 )
221+ rspec-support (~> 3.9 .0 )
222+ rspec-support (3.9.3 )
223223 ruby2_keywords (0.0.2 )
224224 safe_yaml (1.0.5 )
225225 simplecov (0.19.0 )
Original file line number Diff line number Diff line change 33class VersionUtils
44 def self . version
55 begin
6- spec = Gem ::Specification . load ( 'securenative.gemspec' )
7- version = spec . version . to_s
6+ Gem . loaded_specs [ 'securenative' ] . version . to_s
87 rescue StandardError
9- version = 'unknown'
8+ 'unknown'
109 end
11- version
1210 end
1311end
Original file line number Diff line number Diff line change 1+ # frozen_string_literal: true
2+
3+ require 'utils/version_utils'
4+ require 'rspec'
5+
6+ RSpec . describe VersionUtils do
7+ it 'checks that parsing version is valid' do
8+ expect ( VersionUtils . version ) . not_to eq ( 'unknown' )
9+ end
10+ end
You can’t perform that action at this time.
0 commit comments