docbrown/spec/factories/display_ad_events.rb
Jeremy Friesen b56ae3acbb
Extracting constants and tidying tests (#15946)
Prior to this commit, we had a couple of references to magic strings
regarding DisplayAdEvent objects.  This commit seeks to consolidate that
behavior.

In a handful of cases we had javascript variables, but as these JS files
are `erb` templates, we can inject the constant as well.  This reduces
repetition of knowledge.
2022-01-05 09:19:39 -05:00

7 lines
158 B
Ruby

FactoryBot.define do
factory :display_ad_event do
category { DisplayAdEvent::CATEGORY_IMPRESSION }
context_type { "home" }
display_ad
end
end