class TurboTest::Configuration
Constants
- DEFAULT_JOB_CLASSES
Attributes
jobs[RW]
loaded[RW]
worker[RW]
Public Class Methods
new()
click to toggle source
# File lib/turbo_test/configuration.rb, line 27 def initialize @loaded = false @worker = nil @jobs = [] end
Public Instance Methods
defaults!(pwd = Dir.pwd)
click to toggle source
# File lib/turbo_test/configuration.rb, line 62 def defaults!(pwd = Dir.pwd) loader = Loader.new(self, pwd) loader.defaults! return loader end
finalize!()
click to toggle source
# File lib/turbo_test/configuration.rb, line 45 def finalize! unless @loaded self.defaults! end end
load(path)
click to toggle source
# File lib/turbo_test/configuration.rb, line 37 def load(path) loader = Loader.new(self, File.dirname(path)) loader.instance_eval(File.read(path), path.to_s) return loader end
queue(matching)
click to toggle source
# File lib/turbo_test/configuration.rb, line 51 def queue(matching) if matching.nil? or matching.empty? # No filtering required, return all jobs: return @jobs.dup else return @jobs.select{|klass, path| matching.include?(path)} end end