diff options
Diffstat (limited to 'app/models/integrations/mock_ci.rb')
-rw-r--r-- | app/models/integrations/mock_ci.rb | 18 |
1 files changed, 5 insertions, 13 deletions
diff --git a/app/models/integrations/mock_ci.rb b/app/models/integrations/mock_ci.rb index 568fb609a44..cd2928136ef 100644 --- a/app/models/integrations/mock_ci.rb +++ b/app/models/integrations/mock_ci.rb @@ -7,7 +7,11 @@ module Integrations ALLOWED_STATES = %w[failed canceled running pending success success-with-warnings skipped not_found].freeze - prop_accessor :mock_service_url + field :mock_service_url, + title: s_('ProjectService|Mock service URL'), + placeholder: 'http://localhost:4004', + required: true + validates :mock_service_url, presence: true, public_url: true, if: :activated? def title @@ -22,18 +26,6 @@ module Integrations 'mock_ci' end - def fields - [ - { - type: 'text', - name: 'mock_service_url', - title: s_('ProjectService|Mock service URL'), - placeholder: 'http://localhost:4004', - required: true - } - ] - end - # Return complete url to build page # # Ex. |