You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, seems like there is a false positive when used together with FactoryBot create_list. I'm not sure if the problem is in Prosopite codebase or somewhere else, but I'd like to hear others' thoughts.
I created a reproduction script:
# frozen_string_literal: truerequire"bundler/inline"gemfile(true)dosource"https://rubygems.org"git_source(:github){ |repo| "https://github.com/#{repo}.git"}# Activate the gem you are reporting the issue against.gem"rails","~> 7.0.0"gem"sqlite3","~> 1.6.4"gem"prosopite","~> 1.3.3"gem"pg_query","~> 4.2.3"gem"factory_bot_rails","~> 6.2.0"endrequire"active_record/railtie"require"active_storage/engine"require"tmpdir"require"minitest/autorun"classTestApp < Rails::Applicationconfig.root=__dir__config.hosts << "example.org"config.eager_load=falseconfig.session_store:cookie_store,key: "cookie_store_key"config.secret_key_base="secret_key_base"config.logger=Logger.new($stdout)Rails.logger=config.loggerconfig.active_storage.service=:localconfig.active_storage.service_configurations={local: {root: Dir.tmpdir,service: "Disk"}}endENV["DATABASE_URL"]="sqlite3::memory:"Rails.application.config.after_initializedoProsopite.rails_logger=trueProsopite.raise=trueendRails.application.initialize!requireActiveStorage::Engine.root.join("db/migrate/20170806125915_create_active_storage_tables.rb").to_sActiveRecord::Schema.definedoCreateActiveStorageTables.new.changecreate_table:users,force: trueendclassUser < ActiveRecord::Basehas_one_attached:profileendFactoryBot.definedofactory:userdoprofile{{content_type: "text/plain",filename: "dummy.txt",io: ::StringIO.new("dummy")}}endendclassBugTest < Minitest::TestdefsetupProsopite.scanenddefteardownProsopite.finishenddeftest_it_worksFactoryBot.create(:user)FactoryBot.create(:user)enddeftest_it_doesnt_workFactoryBot.create_list(:user,2)endend
as you can see, two create works fine, but one create_list(.., 2) doesn't
The text was updated successfully, but these errors were encountered:
Hi, seems like there is a false positive when used together with FactoryBot
create_list
. I'm not sure if the problem is in Prosopite codebase or somewhere else, but I'd like to hear others' thoughts.I created a reproduction script:
as you can see, two
create
works fine, but onecreate_list(.., 2)
doesn'tThe text was updated successfully, but these errors were encountered: