FactoryBot.define do
  factory :ci_bridge, class: Ci::Bridge do
    name ' bridge'
    stage 'test'
    stage_idx 0
    ref 'master'
    tag false
    created_at 'Di 29. Okt 09:50:00 CET 2013'
    status :success

    pipeline factory: :ci_pipeline

    trait :variables do
      yaml_variables [{ key: 'BRIDGE', value: 'cross', public: true }]
    end

    transient { downstream nil }

    after(:build) do |bridge, evaluator|
      bridge.project ||= bridge.pipeline.project

      if evaluator.downstream.present?
        bridge.options = bridge.options.to_h.merge(
          trigger: { project: evaluator.downstream.full_path }
        )
      end
    end
  end
end

FactoryBot.define do
  factory :ci_bridge, class: Ci::Bridge do
    name 'bridge'
    stage 'test'
    stage_idx 0
    ref 'master'
    tag false
    created_at 'Di 29. Okt 09:50:00 CET 2013'
    status :success

    pipeline factory: :ci_pipeline

    trait :variables do
      yaml_variables [{ key: 'BRIDGE', value: 'cross', public: true }]
    end

    transient { downstream nil }

    after(:build) do |bridge, evaluator|
      bridge.project ||= bridge.pipeline.project

      if evaluator.downstream.present?
        bridge.options = bridge.options.to_h.merge(
          trigger: { project: evaluator.downstream.full_path }
        )
      end
    end
  end
end

Remove an extra whitespace in test files
Remove an extra whitespace in test files

Partial CE backport of https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/10565

Signed-off-by: Takuya Noguchi <b6ff22f4ae6fe3ca1371a0ef8d104f1c4bca551b@gmail.com>
