test_track_rails_client 4.0.0.alpha22 → 4.0.0.alpha23

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3dfcb06b82a4dde27f4e0d5237399e3e5ad5a014
4
- data.tar.gz: ac1ffd9164aaadbd8f21e27c6dd97ff1a8c4375c
3
+ metadata.gz: 2aa99a6380a919dfd903ab199a396011ceaad5aa
4
+ data.tar.gz: ab34fad82d0c67e28152cd96c103d9b5f2dc184c
5
5
  SHA512:
6
- metadata.gz: 6e7ac5454a61f970ef354055dd1e25b91fefe3769f3dea52879ec54fb50e90954f7df221b61561c9214b3cd3812add6493c4b290710d53977cb251c70761a1bb
7
- data.tar.gz: 128e7d688e98d3223d2d1f0c5fd1fb12daff8aa052b42f9f4252dce131e5de8a97bd12525bb4da5550e6308140c212b3ccf784fc5fd8db3c4abc70db72ed29ce
6
+ metadata.gz: 213cb4c0bd274d577a745b4ae9da6e57ffa843ee81939bebba5b4fd3a982e3a2a6aeeb23a9b69ada611adc5d141aa842cb95022f061257b431f766a2607bb751
7
+ data.tar.gz: f6f355680560349991d3b8fb50b59b778f5cd42d17223f345a1f9e4959d528f32d26749feba2bf3a1bba78a29b2fc14df0dc238d38cd46eef0588695663e4519
@@ -33,7 +33,8 @@ class TestTrack::Fake::SplitRegistry
33
33
  end
34
34
 
35
35
  def _schema_registry
36
- file = YAML.load_file(schema_yml_path)
36
+ file = File.exist?(schema_yml_path) &&
37
+ YAML.load_file(schema_yml_path)
37
38
  file && file['splits'].each_with_object(ActiveSupport::HashWithIndifferentAccess.new) do |split, h|
38
39
  h[split['name']] = split['weights']
39
40
  end
@@ -52,13 +53,14 @@ class TestTrack::Fake::SplitRegistry
52
53
  end
53
54
 
54
55
  def _legacy_test_track_schema_yml
55
- YAML.load_file(legacy_test_track_schema_yml_path).with_indifferent_access
56
+ File.exist?(legacy_test_track_schema_yml_path) &&
57
+ YAML.load_file(legacy_test_track_schema_yml_path).with_indifferent_access
56
58
  rescue
57
59
  nil
58
60
  end
59
61
 
60
62
  def legacy_test_track_schema_yml_path
61
- ENV["TEST_TRACK_SCHEMA_FILE_PATH"] || Rails.root.join('db', 'test_track_schema.yml')
63
+ ENV["TEST_TRACK_SCHEMA_FILE_PATH"] || Rails.root.join('db', 'test_track_schema.yml').to_s
62
64
  end
63
65
 
64
66
  def splits_with_deterministic_weights
@@ -1,3 +1,3 @@
1
1
  module TestTrackRailsClient
2
- VERSION = "4.0.0.alpha22" # rubocop:disable Style/MutableConstant
2
+ VERSION = "4.0.0.alpha23" # rubocop:disable Style/MutableConstant
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: test_track_rails_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0.alpha22
4
+ version: 4.0.0.alpha23
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan O'Neill
@@ -13,7 +13,7 @@ authors:
13
13
  autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
- date: 2019-05-05 00:00:00.000000000 Z
16
+ date: 2019-05-07 00:00:00.000000000 Z
17
17
  dependencies:
18
18
  - !ruby/object:Gem::Dependency
19
19
  name: airbrake