diff --git a/lib/veracode/api/builds.rb b/lib/veracode/api/builds.rb index 01250cd..2254549 100644 --- a/lib/veracode/api/builds.rb +++ b/lib/veracode/api/builds.rb @@ -46,7 +46,12 @@ def analysis_units return @analysis_units end end - + + class CustomField < Veracode::Common::Base + api_field :name, :tag => :name + api_field :value, :tag => :value + end + class Application < Veracode::Common::Base api_field :app_name, :tag => :app_name api_field :app_id, :tag => :app_id @@ -59,7 +64,14 @@ class Application < Veracode::Common::Base api_field :modified_date, :tag => :modified_date api_field :vendor, :tag => :vendor api_field :tags, :tag => :tags - + + def custom_fields + @custom_fields ||= + @xml_hash.customfield.map do |customfield| + CustomField.new(customfield) + end + end + def cots? @cots ||= @xml_hash.cots.to_bool end