Class: Megatest::Selector::NegativeLoader

Inherits:
Object
  • Object
show all
Defined in:
lib/megatest/selector.rb

Instance Method Summary collapse

Constructor Details

#initialize(loader) ⇒ NegativeLoader

Returns a new instance of NegativeLoader.



105
106
107
# File 'lib/megatest/selector.rb', line 105

def initialize(loader)
  @loader = loader
end

Instance Method Details

#append_paths(paths_to_load) ⇒ Object



113
114
115
116
117
118
119
120
# File 'lib/megatest/selector.rb', line 113

def append_paths(paths_to_load)
  if @loader.partial?
    paths_to_load
  else
    paths_to_not_load = @loader.append_paths([])
    paths_to_load - paths_to_not_load
  end
end

#append_tests(tests_to_run, registry, random:) ⇒ Object



122
123
124
125
# File 'lib/megatest/selector.rb', line 122

def append_tests(tests_to_run, registry, random:)
  tests_to_not_run = @loader.append_tests([], registry, random: nil)
  tests_to_run - tests_to_not_run
end

#partial?Boolean

Returns:

  • (Boolean)


109
110
111
# File 'lib/megatest/selector.rb', line 109

def partial?
  @loader.partial?
end