BigW Consortium Gitlab

deployments.rb 327 Bytes
Newer Older
1 2 3 4
FactoryGirl.define do
  factory :deployment, class: Deployment do
    sha '97de212e80737a608d939f648d959671fb0a0142'
    ref 'master'
Kamil Trzcinski committed
5
    tag false
6
    project nil
7 8 9 10

    environment factory: :environment

    after(:build) do |deployment, evaluator|
11
      deployment.project ||= deployment.environment.project
12 13 14
    end
  end
end