Commit 0e4178ae authored by Rajendra Kadam's avatar Rajendra Kadam

Add spec for ff flag

parent 31f3e92f
......@@ -32,6 +32,15 @@ RSpec.describe Gitlab::SnowplowEventDefinitionGenerator do
expect(::Gitlab::Config::Loader::Yaml.new(File.read(event_definition_path)).load_raw!).to eq(sample_event)
end
it 'overwrites event definition file using the template' do
sample_event = ::Gitlab::Config::Loader::Yaml.new(fixture_file(File.join(sample_event_dir, 'sample_event.yml'))).load_raw!
described_class.new([], generator_options.merge('ff' => true)).invoke_all
event_definition_path = File.join(ce_temp_dir, 'groups__email_campaigns_controller_click.yml')
expect(::Gitlab::Config::Loader::Yaml.new(File.read(event_definition_path)).load_raw!).to eq(sample_event)
end
it 'creates EE event definition file using the template' do
sample_event = ::Gitlab::Config::Loader::Yaml.new(fixture_file(File.join(sample_event_dir, 'sample_event_ee.yml'))).load_raw!
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment