diff options
author | Shinya Maeda <shinya@gitlab.com> | 2017-11-22 12:31:07 +0300 |
---|---|---|
committer | Shinya Maeda <shinya@gitlab.com> | 2017-11-28 14:47:59 +0300 |
commit | 45f2d0af4173ae8e06b548c4bef1fabe14353c85 (patch) | |
tree | 4036b5f257b0f07a42431a2c2cff41dcbdd28dd1 /app/models | |
parent | a8e2094c6591336405a90e4185e89752d38965bf (diff) |
Add test suit for platform::kubernetes
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/project.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/app/models/project.rb b/app/models/project.rb index 512fe77261a..a7f90bc7fc3 100644 --- a/app/models/project.rb +++ b/app/models/project.rb @@ -914,13 +914,6 @@ class Project < ActiveRecord::Base deployment_platform end - # TODO: This will be extended for multiple enviroment clusters - # TODO: Add super nice tests to check this interchangeability - def deployment_platform - @deployment_platform ||= clusters.where(enabled: true).first&.platform_kubernetes - @deployment_platform ||= deployment_services.reorder(nil).find_by(active: true) - end - def monitoring_services services.where(category: :monitoring) end @@ -1858,4 +1851,11 @@ class Project < ActiveRecord::Base raise ex end + + # TODO: This will be extended for multiple enviroment clusters + # TODO: Add super nice tests to check this interchangeability + def deployment_platform + @deployment_platform ||= clusters.where(enabled: true).first&.platform_kubernetes + @deployment_platform ||= deployment_services.reorder(nil).find_by(active: true) + end end |