diff options
author | Steve Azzopardi <steveazz@outlook.com> | 2018-09-04 10:51:00 +0300 |
---|---|---|
committer | Steve Azzopardi <steveazz@outlook.com> | 2018-09-12 12:00:39 +0300 |
commit | 1b388c798b01d950ad8692e34938a2a457c6ad0f (patch) | |
tree | 96471170bf1da744b6c043212a78c09df768a17d /app/serializers/trigger_variable_entity.rb | |
parent | f87809f78de9da04f38134ba5ce0cf9ddebf2f63 (diff) |
Add trigger information for job API
Create new entity called TriggerVariablesEnitity for trigger variables,
to aid reuseablity in the future.
Update JSON schema to include trigger information in the response.
Refactor rspec tests a bit to reduce duplication and for the `context`
to make sense.
closes https://gitlab.com/gitlab-org/gitlab-ce/issues/50989
Diffstat (limited to 'app/serializers/trigger_variable_entity.rb')
-rw-r--r-- | app/serializers/trigger_variable_entity.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/serializers/trigger_variable_entity.rb b/app/serializers/trigger_variable_entity.rb new file mode 100644 index 00000000000..56203113631 --- /dev/null +++ b/app/serializers/trigger_variable_entity.rb @@ -0,0 +1,7 @@ +# frozen_string_literal: true + +class TriggerVariableEntity < Grape::Entity + include RequestAwareEntity + + expose :key, :value, :public +end |