Sha256: 10d21fb6d3ade52ed3b2925d4394ce0d78ed546c6cafa9aad44405a6246d2354

Contents?: true

Size: 1.17 KB

Versions: 113

Compression:

Stored size: 1.17 KB

Contents

Feature: Diagnostic Mode
  To help a developer quickly pinpoint why files are being loaded
  Spork provides a diagnostic mode
  That provides a list of which project files were loaded during prefork, and who loaded them.

  Scenario: Running spork --diagnose
    Given I am in the directory "test_project"
    And a file named "spec/spec_helper.rb" with:
      """
      require 'rubygems'
      require 'spork'

      Spork.prefork do
        require 'lib/awesome.rb'
        require '../external_dependency/super_duper.rb'
      end

      Spork.each_run do
        puts "I'm loading the stuff just for this run..."
      end
      """
    And a file named "lib/awesome.rb" with:
      """
      class Awesome
      end
      """
    And a file named "../external_dependency/super_duper.rb" with:
      """
      class Awesome
      end
      """
    When I run spork --diagnose
    Then the error output should contain
      """
      Loading Spork.prefork block...
      """
    And the output should contain "lib/awesome.rb"
    And the output should contain "spec/spec_helper.rb:5"
    And the output should not contain "super_duper.rb"
    And the output should not contain "diagnose.rb"
     

Version data entries

113 entries across 113 versions & 11 rubygems

Version Path
panjiva-spork-0.8.6 features/diagnostic_mode.feature
panjiva-spork-0.8.5.1 features/diagnostic_mode.feature
panjiva-spork-0.8.5 features/diagnostic_mode.feature
classiccms-0.7.5 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
classiccms-0.7.4 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
classiccms-0.7.3 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
bmabey-spork-0.5.9 features/diagnostic_mode.feature
timcharper-spork-0.5.10 features/diagnostic_mode.feature
timcharper-spork-0.5.9 features/diagnostic_mode.feature
timcharper-spork-0.6.0 features/diagnostic_mode.feature
timcharper-spork-0.6.1 features/diagnostic_mode.feature
timcharper-spork-0.6.2 features/diagnostic_mode.feature
timcharper-spork-0.6.3 features/diagnostic_mode.feature
classiccms-0.7.2 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
classiccms-0.7.1 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
classiccms-0.7.0 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
classiccms-0.6.9 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
classiccms-0.6.8 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
classiccms-0.6.7 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature
classiccms-0.6.6 vendor/bundle/gems/spork-0.9.0/features/diagnostic_mode.feature