title: What constitutes Ruby coverage measurement with simplecov gem
body: <p>While running <code>simplecov</code> on Mac OSX, the resulting coverage makes little sense.</p>
  <p>If the following test is run:</p>
  <pre><code>rails test test/models/channel_test.rb
  &gt; 4 runs, 4 assertions, 0 failures, 0 errors, 0 skips
  &gt; Coverage report generated for Minitest to /Volumes/[...]/coverage. 0 / 0 LOC (100.0%) covered.
  </code></pre>
  <p>Yet when running <code>rails test test/models</code> the graphical output indicates for <code>test/models/channel_test.rb</code></p>
  <pre><code>require &quot;test_helper&quot; 
  class ChannelTest &lt; ActiveSupport::TestCase 
    test &quot;invalid if name not defined&quot; do  
      channel = Channel.new(priority: 1, unit_cost: 1, daily_limit: 9999) 
      assert_not channel.valid?  
      assert_not channel.save, &quot;Saved the channel without a name&quot;
    end   
  </code></pre>
  <p><strong>update</strong>  I presumed it might have been the chosen syntax of the test that might be a flaw - I added a supplemental test and the result is still reported<br />
  for the model  <code>3 relevant lines. 0 lines covered and 3 lines missed.</code></p>
  <pre><code>class Channel &lt; ApplicationRecord # red
  
    validates :name, presence: true # red
  
  end # red
  </code></pre>
  <p>Thus the test is passing, but the coverage result is confounding:</p>
  <p>a) as a standalone, the coverage count is <code>0/0</code>, whereas the tests pass</p>
  <p>b) what constitutes a <code>miss</code> or conversely <code>coverage</code> by a (the?) test ?</p>
  <p>test_helper.rb</p>
  <pre><code> require 'simplecov'
   SimpleCov.start
  
  ENV['RAILS_ENV'] ||= 'test'
  require_relative &quot;../config/environment&quot;
  require &quot;rails/test_help&quot;
  require 'webmock/minitest'
  
  
  class ActiveSupport::TestCase
    parallelize(workers: :number_of_processors)
  
  
    fixtures :all
  
    def log_in_as(user, shop)
      post user_session_url, params: { user_id: user.id, active_shop_id: @site.shop_id }
    end
  
  end
  
  </code></pre>
  <p><strong>Update 2</strong>  As per @BroiSatse suggestion, commenting out <code>parallelize(workers: :number_of_processors)</code>
  allows coverage to be measured.</p>