Skip to content

Commit

Permalink
Don't run simplecov on alternate Ruby (#1563)
Browse files Browse the repository at this point in the history
The truffleruby + Rails 7.0 build was failing because of some kind of
simplecov incompatibility. I don't think we need to run simplecov on the
truffleruby and jruby builds (we might not need it on any build—it
prints some output but doesn't affect the build status at all—but I
figured I'd leave it alone for now in case somebody is looking at it).

I needed to add a fileutils require to one test that was presumably
getting implicitly required before via simplecov.
  • Loading branch information
composerinteralia authored Jan 3, 2023
1 parent b5287b7 commit 50a4443
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion features/support/env.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PROJECT_ROOT = File.expand_path(File.join(File.dirname(__FILE__), "..", ".."))

require "simplecov"
require "simplecov" if RUBY_ENGINE == "ruby"

$: << File.join(PROJECT_ROOT, "lib")

Expand Down
2 changes: 2 additions & 0 deletions spec/factory_bot/find_definitions_spec.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
require "fileutils"

shared_examples_for "finds definitions" do
before do
allow(FactoryBot).to receive(:load)
Expand Down
2 changes: 1 addition & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
require "rspec"
require "rspec/its"

require "simplecov"
require "simplecov" if RUBY_ENGINE == "ruby"

require "factory_bot"

Expand Down

0 comments on commit 50a4443

Please sign in to comment.