boomerdigital / solidus_flexi_variants

BSD 3-Clause "New" or "Revised" License
15 stars 31 forks source link

Factories are defined twice #21

Open fastjames opened 4 years ago

fastjames commented 4 years ago

I ran into a problem this morning where I was getting some errors about factories being defined twice. I then noticed that most of the factories are defined both in lib/solidus_flexi_variants/factories.rb and in individual files under spec/factories. I don't know if this is a recent change in factory_bot or a convention with which I'm not familiar (I am used to looking for one factories file in a gem).

I am happy to remove one set or the other.

dhonig commented 4 years ago

Not sure how this came about. My vote is for spec/factories to live on and to drop the ones under lib. Doesn't really make much sense to have code for testing co-mingled with the functional code.