BigW Consortium Gitlab

deployments.rb 369 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
    user
7
    project nil
8
    deployable factory: :ci_build
9 10 11
    environment factory: :environment

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