Class: Tester
- Inherits:
-
Object
- Object
- Tester
- Defined in:
- lib/sfb_scripts/tester.rb
Instance Attribute Summary collapse
-
#env ⇒ Object
Returns the value of attribute env.
Class Method Summary collapse
- .find(inputs, options) ⇒ Object
- .needs ⇒ Object
- .status(options) ⇒ Object
- .status_check(options) ⇒ Object
Instance Method Summary collapse
- #find(input) ⇒ Object
-
#initialize(env) ⇒ Tester
constructor
A new instance of Tester.
- #status(options) ⇒ Object
- #status_check(options) ⇒ Object
Constructor Details
#initialize(env) ⇒ Tester
Returns a new instance of Tester.
25 26 27 |
# File 'lib/sfb_scripts/tester.rb', line 25 def initialize(env) @env = env end |
Instance Attribute Details
#env ⇒ Object
Returns the value of attribute env.
24 25 26 |
# File 'lib/sfb_scripts/tester.rb', line 24 def env @env end |
Class Method Details
.find(inputs, options) ⇒ Object
9 10 11 12 |
# File 'lib/sfb_scripts/tester.rb', line 9 def self.find(inputs, ) env = NeedsManager.configure(:test_runner, needs, .merge(repo_type: :info)) new(env).find(inputs) end |
.needs ⇒ Object
5 6 7 |
# File 'lib/sfb_scripts/tester.rb', line 5 def self.needs [:shell, :repo, :test_runner] end |
.status(options) ⇒ Object
14 15 16 17 |
# File 'lib/sfb_scripts/tester.rb', line 14 def self.status() env = NeedsManager.configure(:test_runner, needs, .merge(repo_type: :info)) new(env).status() end |
.status_check(options) ⇒ Object
19 20 21 22 |
# File 'lib/sfb_scripts/tester.rb', line 19 def self.status_check() env = NeedsManager.configure(:test_runner, (needs - [:test_runner]), .merge(repo_type: :info)) new(env).status_check() end |
Instance Method Details
#find(input) ⇒ Object
29 30 31 32 33 34 |
# File 'lib/sfb_scripts/tester.rb', line 29 def find(input) tests = TestFinder.find(input, env) env[:test_runner].run(tests) env[:shell].warn "Giving up :(" end |
#status(options) ⇒ Object
36 37 38 |
# File 'lib/sfb_scripts/tester.rb', line 36 def status() StatusTestRunner.status(env, [:no_selenium]) end |
#status_check(options) ⇒ Object
40 41 42 |
# File 'lib/sfb_scripts/tester.rb', line 40 def status_check() StatusChecker.report(env, [:confirm_exit_status]) end |