Class: Minitest::Distributed::Filters::FileFilterBase
- Inherits:
-
Object
- Object
- Minitest::Distributed::Filters::FileFilterBase
- Extended by:
- T::Sig
- Defined in:
- lib/minitest/distributed/filters/file_filter_base.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#file ⇒ Object
readonly
Returns the value of attribute file.
Instance Method Summary collapse
-
#initialize(file) ⇒ FileFilterBase
constructor
A new instance of FileFilterBase.
- #tests ⇒ Object
Constructor Details
#initialize(file) ⇒ FileFilterBase
Returns a new instance of FileFilterBase.
14 15 16 17 |
# File 'lib/minitest/distributed/filters/file_filter_base.rb', line 14 def initialize(file) @file = file @tests = T.let(nil, T.nilable(T::Set[String])) end |
Instance Attribute Details
#file ⇒ Object (readonly)
Returns the value of attribute file.
11 12 13 |
# File 'lib/minitest/distributed/filters/file_filter_base.rb', line 11 def file @file end |
Instance Method Details
#tests ⇒ Object
20 21 22 23 24 25 |
# File 'lib/minitest/distributed/filters/file_filter_base.rb', line 20 def tests @tests ||= begin tests = File.readlines(@file, chomp: true) Set.new(tests) end end |