Module: Minitest::Snapshots
- Defined in:
- lib/minitest/snapshots/version.rb,
lib/minitest/snapshots/serializer.rb,
lib/minitest/snapshots/test_extensions.rb,
lib/minitest/snapshots.rb
Defined Under Namespace
Modules: Serializer, TestExtensions
Constant Summary collapse
- VERSION =
"1.1.2".freeze
Class Attribute Summary collapse
-
.force_updates ⇒ Object
Returns the value of attribute force_updates.
-
.lock_snapshots ⇒ Object
Returns the value of attribute lock_snapshots.
Class Method Summary collapse
Class Attribute Details
.force_updates ⇒ Object
Returns the value of attribute force_updates.
5 6 7 |
# File 'lib/minitest/snapshots.rb', line 5 def force_updates @force_updates end |
.lock_snapshots ⇒ Object
Returns the value of attribute lock_snapshots.
5 6 7 |
# File 'lib/minitest/snapshots.rb', line 5 def lock_snapshots @lock_snapshots end |
Class Method Details
.default_snapshots_directory ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/minitest/snapshots.rb', line 7 def default_snapshots_directory if defined?(Rails) && Rails.respond_to?(:root) Rails.root.join("test", "snapshots").to_s elsif Dir.exist?("test") File.("test/snapshots") elsif Dir.exist?("spec") File.("spec/snapshots") else File.("snapshots") end end |