title: in my rspec test suite, how can I populate a static table with config data my app uses?
body: <p>So far I use rspec and factories only, not fixtures or seed data. But now I need a (static) Coupon table with a dozen or so records of config data to be available to my app when running my integration tests (rspec + capybara, not cuke).</p>
  
  <p>My rspec tests have a FactoryGirl factory that creates a Store.</p>
  
  <p>In my app, when a Store is initialized by init_store(coupon_code), a coupon code is passed in that turns on/off various features (by looking up the settings for that coupon in Coupon table).</p>
  
  <p>So, when I create a Store factory, I also need to specify (via trait?) a coupon code. Then, down in my model, the method that initializes a store will use the coupon code to lookup a bunch of settings in the Coupon table. (Each coupon has about 20 attributes that turn on/off various Store features.)</p>
  
  <p>My coupons.yml file contains the actual coupon table data used by my app. Now I need to make them available to the app when tests are being run. (Don't care about 'brittle', this table doesn't change.)</p>
  
  <p>Having not used fixtures OR seed data with rspec, I'm not sure how/where to put my coupons.yml file and how to make the coupons 'load' into the test Coupon table so they are available to my app while tests are running.</p>
  
  <p>Do I pre-populate seed data with coupons.yml? If so, how can I have that get loaded into my test database each time my tests run?</p>
  
  <p>Or, should I use fixtures?</p>
  
  <p>Either way, where should coupons.yml go and how do I load it (in the Store factories? in one of the specs? In specs_helper?)</p>
  
  <p>When I search for stuff like "using fixtures and factories" or "using seed data with rspec" all I find is the advice "use factories" and yeah, I get that. But for this particular situation I need both, so any help would be appreciated.</p>