fixtury 0.3.4 → 0.3.5

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
  SHA256:
3
- metadata.gz: 6e98c0301a74feb23eac901666363ac54ed521d91a497a3e24c981cc7237edb9
4
- data.tar.gz: 949cd3db96159d072029ee2c7ca2b04579fd99cb471d1a22d75a2f0b72d8aced
3
+ metadata.gz: d422110eda024f73368d6d4e244f909fcbc0b288a223df00e7b527c18f551b13
4
+ data.tar.gz: 440dd84ef120db60bd9cad4bcdac952e43c61c915199801c27023c95775725c5
5
5
  SHA512:
6
- metadata.gz: 2ecd015fa82cbe560932a73b303cde3132614efaa8d231f6e0dea0272086c8b0441d7964a10039ded2fb5c64e89ff5a74835b9054fbfc1d675a42f479294142f
7
- data.tar.gz: 1a8d220621bcdb4aff855fcd7cba8bfd51cd542bf3361747abba7e159fed2bdd2428d284cff3173829abda2ea9d27a8540cd687e4b65b1ce0345ec6e6b4efdf0
6
+ metadata.gz: 8b7c93a1dc5781514337168f86407a0db1c05b0697df2cfb2a595b7766f02f7fcf762b5a1102984e1b18bfcaaaa02d756128c6af4bbb2072a99c13f99809d068
7
+ data.tar.gz: 2fad96dd5f9aa75f8af8f0bfc62e15864d3fd70289dc353b8431fee1362bcd53842261b37b5fcba58d583177f9ef7aa0bea4426d81ddd8ab13b097ab76ff03d0
@@ -130,7 +130,7 @@ module Fixtury
130
130
  end
131
131
 
132
132
  def setup_fixtury_fixtures
133
- return unless use_transactional_fixtures
133
+ return unless fixtury_use_transactions?
134
134
 
135
135
  clear_expired_fixtury_fixtures!
136
136
  load_all_fixtury_fixtures!
@@ -141,7 +141,7 @@ module Fixtury
141
141
  end
142
142
 
143
143
  def teardown_fixtury_fixtures
144
- return unless use_transactional_fixtures
144
+ return unless fixtury_use_transactions?
145
145
 
146
146
  fixtury_database_connections.each(&:rollback_transaction)
147
147
  end
@@ -158,5 +158,12 @@ module Fixtury
158
158
  end
159
159
  end
160
160
 
161
+ def fixtury_use_transactions?
162
+ return use_transactional_tests if respond_to?(:use_transactional_tests)
163
+ return use_transactional_fixtures if respond_to?(:use_transactional_fixtures)
164
+
165
+ true
166
+ end
167
+
161
168
  end
162
169
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Fixtury
4
4
 
5
- VERSION = "0.3.4"
5
+ VERSION = "0.3.5"
6
6
 
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fixtury
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.4
4
+ version: 0.3.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Nelson
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-10-23 00:00:00.000000000 Z
11
+ date: 2020-10-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: autotest