Class: Thrust::Tasks::FocusedSpecs
- Inherits:
-
Object
- Object
- Thrust::Tasks::FocusedSpecs
- Defined in:
- lib/thrust/tasks/focused_specs.rb
Constant Summary collapse
- FOCUSED_METHODS =
%w[fit(@ fcontext(@ fdescribe(@]
Instance Method Summary collapse
-
#initialize(executor = Thrust::Executor.new) ⇒ FocusedSpecs
constructor
A new instance of FocusedSpecs.
- #run(thrust) ⇒ Object
Constructor Details
#initialize(executor = Thrust::Executor.new) ⇒ FocusedSpecs
Returns a new instance of FocusedSpecs.
6 7 8 |
# File 'lib/thrust/tasks/focused_specs.rb', line 6 def initialize(executor = Thrust::Executor.new) @executor = executor end |
Instance Method Details
#run(thrust) ⇒ Object
10 11 12 13 14 |
# File 'lib/thrust/tasks/focused_specs.rb', line 10 def run(thrust) pattern = FOCUSED_METHODS.join("\\|") directories = thrust.app_config.ios_spec_targets.values.map(&:target).join(' ') @executor.system_or_exit %Q[grep -l -r -e "\\(#{pattern}\\)" #{directories} | grep -v 'Frameworks'; exit 0] end |