Apipie / apipie-rails

Ruby on Rails API documentation tool
Apache License 2.0
2.47k stars 461 forks source link

RSpec/EmptyExampleGroup-20230313233258 #845

Closed github-actions[bot] closed 1 year ago

github-actions[bot] commented 1 year ago

Rubocop challenge!

RSpec/EmptyExampleGroup

Safe autocorrect: No :warning: The autocorrect a cop can yield false positives by design.

Description

Overview

Checks if an example group does not include any tests.

Examples

usage

# bad
describe Bacon do
  let(:bacon)      { Bacon.new(chunkiness) }
  let(:chunkiness) { false                 }

  context 'extra chunky' do   # flagged by rubocop
    let(:chunkiness) { true }
  end

  it 'is chunky' do
    expect(bacon.chunky?).to be_truthy
  end
end

# good
describe Bacon do
  let(:bacon)      { Bacon.new(chunkiness) }
  let(:chunkiness) { false                 }

  it 'is chunky' do
    expect(bacon.chunky?).to be_truthy
  end
end

# good
describe Bacon do
  pending 'will add tests later'
end

Auto generated by rubocop_challenger