dependency-tracker-client 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/LICENSE +201 -0
- data/README.md +276 -0
- data/Rakefile +10 -0
- data/dependency-tracker-client.gemspec +39 -0
- data/docs/About.md +25 -0
- data/docs/Analysis.md +21 -0
- data/docs/AnalysisApi.md +177 -0
- data/docs/AnalysisComment.md +21 -0
- data/docs/AnalysisRequest.md +27 -0
- data/docs/ApiKey.md +17 -0
- data/docs/BadgeApi.md +102 -0
- data/docs/BodyPart.md +31 -0
- data/docs/BomApi.md +335 -0
- data/docs/BomSubmitRequest.md +25 -0
- data/docs/CalculatorApi.md +61 -0
- data/docs/CloneProjectRequest.md +19 -0
- data/docs/Component.md +69 -0
- data/docs/ComponentApi.md +373 -0
- data/docs/ComponentMetrics.md +43 -0
- data/docs/ConfigProperty.md +25 -0
- data/docs/ConfigPropertyApi.md +167 -0
- data/docs/ContentDisposition.md +29 -0
- data/docs/Cwe.md +19 -0
- data/docs/CweApi.md +110 -0
- data/docs/DefaultApi.md +434 -0
- data/docs/Dependency.md +27 -0
- data/docs/DependencyApi.md +222 -0
- data/docs/DependencyMetrics.md +45 -0
- data/docs/DependencyRequest.md +21 -0
- data/docs/Finding.md +23 -0
- data/docs/FindingApi.md +113 -0
- data/docs/FormDataBodyPart.md +39 -0
- data/docs/FormDataContentDisposition.md +31 -0
- data/docs/FormDataMultiPart.md +35 -0
- data/docs/Framework.md +23 -0
- data/docs/IdentifiableObject.md +17 -0
- data/docs/LdapApi.md +220 -0
- data/docs/LdapUser.md +25 -0
- data/docs/License.md +37 -0
- data/docs/LicenseApi.md +159 -0
- data/docs/ManagedUser.md +37 -0
- data/docs/MappedLdapGroup.md +19 -0
- data/docs/MappedLdapGroupRequest.md +19 -0
- data/docs/MediaType.md +25 -0
- data/docs/MetricsApi.md +922 -0
- data/docs/MultiPart.md +33 -0
- data/docs/NotificationPublisher.md +29 -0
- data/docs/NotificationRule.md +35 -0
- data/docs/PackageURL.md +29 -0
- data/docs/ParameterizedHeader.md +19 -0
- data/docs/Permission.md +19 -0
- data/docs/PermissionApi.md +279 -0
- data/docs/PortfolioMetrics.md +53 -0
- data/docs/Project.md +43 -0
- data/docs/ProjectApi.md +445 -0
- data/docs/ProjectMetrics.md +47 -0
- data/docs/ProjectProperty.md +27 -0
- data/docs/ProjectPropertyApi.md +232 -0
- data/docs/Repository.md +29 -0
- data/docs/RepositoryApi.md +325 -0
- data/docs/RepositoryMetaComponent.md +27 -0
- data/docs/Score.md +23 -0
- data/docs/SearchApi.md +120 -0
- data/docs/SearchResult.md +17 -0
- data/docs/Tag.md +19 -0
- data/docs/Team.md +29 -0
- data/docs/TeamApi.md +432 -0
- data/docs/UserApi.md +715 -0
- data/docs/UserPrincipal.md +27 -0
- data/docs/VersionApi.md +52 -0
- data/docs/Vulnerability.md +69 -0
- data/docs/VulnerabilityApi.md +666 -0
- data/docs/VulnerabilityMetrics.md +23 -0
- data/docs/VulnerableSoftware.md +69 -0
- data/lib/dependency-tracker-client/api/analysis_api.rb +209 -0
- data/lib/dependency-tracker-client/api/badge_api.rb +148 -0
- data/lib/dependency-tracker-client/api/bom_api.rb +382 -0
- data/lib/dependency-tracker-client/api/calculator_api.rb +83 -0
- data/lib/dependency-tracker-client/api/component_api.rb +422 -0
- data/lib/dependency-tracker-client/api/config_property_api.rb +192 -0
- data/lib/dependency-tracker-client/api/cwe_api.rb +136 -0
- data/lib/dependency-tracker-client/api/default_api.rb +491 -0
- data/lib/dependency-tracker-client/api/dependency_api.rb +254 -0
- data/lib/dependency-tracker-client/api/finding_api.rb +140 -0
- data/lib/dependency-tracker-client/api/ldap_api.rb +254 -0
- data/lib/dependency-tracker-client/api/license_api.rb +190 -0
- data/lib/dependency-tracker-client/api/metrics_api.rb +1086 -0
- data/lib/dependency-tracker-client/api/permission_api.rb +342 -0
- data/lib/dependency-tracker-client/api/project_api.rb +504 -0
- data/lib/dependency-tracker-client/api/project_property_api.rb +274 -0
- data/lib/dependency-tracker-client/api/repository_api.rb +376 -0
- data/lib/dependency-tracker-client/api/search_api.rb +143 -0
- data/lib/dependency-tracker-client/api/team_api.rb +486 -0
- data/lib/dependency-tracker-client/api/user_api.rb +796 -0
- data/lib/dependency-tracker-client/api/version_api.rb +78 -0
- data/lib/dependency-tracker-client/api/vulnerability_api.rb +780 -0
- data/lib/dependency-tracker-client/api_client.rb +388 -0
- data/lib/dependency-tracker-client/api_error.rb +57 -0
- data/lib/dependency-tracker-client/configuration.rb +261 -0
- data/lib/dependency-tracker-client/models/about.rb +242 -0
- data/lib/dependency-tracker-client/models/analysis.rb +265 -0
- data/lib/dependency-tracker-client/models/analysis_comment.rb +234 -0
- data/lib/dependency-tracker-client/models/analysis_request.rb +371 -0
- data/lib/dependency-tracker-client/models/api_key.rb +250 -0
- data/lib/dependency-tracker-client/models/body_part.rb +273 -0
- data/lib/dependency-tracker-client/models/bom_submit_request.rb +328 -0
- data/lib/dependency-tracker-client/models/clone_project_request.rb +267 -0
- data/lib/dependency-tracker-client/models/component.rb +900 -0
- data/lib/dependency-tracker-client/models/component_metrics.rb +338 -0
- data/lib/dependency-tracker-client/models/config_property.rb +421 -0
- data/lib/dependency-tracker-client/models/content_disposition.rb +262 -0
- data/lib/dependency-tracker-client/models/cwe.rb +259 -0
- data/lib/dependency-tracker-client/models/dependency.rb +266 -0
- data/lib/dependency-tracker-client/models/dependency_metrics.rb +352 -0
- data/lib/dependency-tracker-client/models/dependency_request.rb +257 -0
- data/lib/dependency-tracker-client/models/finding.rb +239 -0
- data/lib/dependency-tracker-client/models/form_data_body_part.rb +309 -0
- data/lib/dependency-tracker-client/models/form_data_content_disposition.rb +271 -0
- data/lib/dependency-tracker-client/models/form_data_multi_part.rb +295 -0
- data/lib/dependency-tracker-client/models/framework.rb +233 -0
- data/lib/dependency-tracker-client/models/identifiable_object.rb +206 -0
- data/lib/dependency-tracker-client/models/ldap_user.rb +351 -0
- data/lib/dependency-tracker-client/models/license.rb +373 -0
- data/lib/dependency-tracker-client/models/managed_user.rb +480 -0
- data/lib/dependency-tracker-client/models/mapped_ldap_group.rb +255 -0
- data/lib/dependency-tracker-client/models/mapped_ldap_group_request.rb +267 -0
- data/lib/dependency-tracker-client/models/media_type.rb +244 -0
- data/lib/dependency-tracker-client/models/multi_part.rb +284 -0
- data/lib/dependency-tracker-client/models/notification_publisher.rb +388 -0
- data/lib/dependency-tracker-client/models/notification_rule.rb +426 -0
- data/lib/dependency-tracker-client/models/package_url.rb +262 -0
- data/lib/dependency-tracker-client/models/parameterized_header.rb +217 -0
- data/lib/dependency-tracker-client/models/permission.rb +250 -0
- data/lib/dependency-tracker-client/models/portfolio_metrics.rb +378 -0
- data/lib/dependency-tracker-client/models/project.rb +420 -0
- data/lib/dependency-tracker-client/models/project_metrics.rb +356 -0
- data/lib/dependency-tracker-client/models/project_property.rb +430 -0
- data/lib/dependency-tracker-client/models/repository.rb +319 -0
- data/lib/dependency-tracker-client/models/repository_meta_component.rb +305 -0
- data/lib/dependency-tracker-client/models/score.rb +233 -0
- data/lib/dependency-tracker-client/models/search_result.rb +208 -0
- data/lib/dependency-tracker-client/models/tag.rb +252 -0
- data/lib/dependency-tracker-client/models/team.rb +310 -0
- data/lib/dependency-tracker-client/models/user_principal.rb +255 -0
- data/lib/dependency-tracker-client/models/vulnerability.rb +729 -0
- data/lib/dependency-tracker-client/models/vulnerability_metrics.rb +238 -0
- data/lib/dependency-tracker-client/models/vulnerable_software.rb +442 -0
- data/lib/dependency-tracker-client/version.rb +15 -0
- data/lib/dependency-tracker-client.rb +109 -0
- data/pkg/dependency-tracker-client-1.0.0.gem +0 -0
- data/spec/api/analysis_api_spec.rb +70 -0
- data/spec/api/badge_api_spec.rb +58 -0
- data/spec/api/bom_api_spec.rb +106 -0
- data/spec/api/calculator_api_spec.rb +46 -0
- data/spec/api/component_api_spec.rb +110 -0
- data/spec/api/config_property_api_spec.rb +67 -0
- data/spec/api/cwe_api_spec.rb +56 -0
- data/spec/api/default_api_spec.rb +123 -0
- data/spec/api/dependency_api_spec.rb +79 -0
- data/spec/api/finding_api_spec.rb +57 -0
- data/spec/api/ldap_api_spec.rb +79 -0
- data/spec/api/license_api_spec.rb +66 -0
- data/spec/api/metrics_api_spec.rb +233 -0
- data/spec/api/permission_api_spec.rb +94 -0
- data/spec/api/project_api_spec.rb +126 -0
- data/spec/api/project_property_api_spec.rb +82 -0
- data/spec/api/repository_api_spec.rb +100 -0
- data/spec/api/search_api_spec.rb +59 -0
- data/spec/api/team_api_spec.rb +122 -0
- data/spec/api/user_api_spec.rb +183 -0
- data/spec/api/version_api_spec.rb +46 -0
- data/spec/api/vulnerability_api_spec.rb +177 -0
- data/spec/api_client_spec.rb +226 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/about_spec.rb +65 -0
- data/spec/models/analysis_comment_spec.rb +53 -0
- data/spec/models/analysis_request_spec.rb +75 -0
- data/spec/models/analysis_spec.rb +57 -0
- data/spec/models/api_key_spec.rb +41 -0
- data/spec/models/body_part_spec.rb +83 -0
- data/spec/models/bom_submit_request_spec.rb +65 -0
- data/spec/models/clone_project_request_spec.rb +47 -0
- data/spec/models/component_metrics_spec.rb +119 -0
- data/spec/models/component_spec.rb +201 -0
- data/spec/models/config_property_spec.rb +69 -0
- data/spec/models/content_disposition_spec.rb +77 -0
- data/spec/models/cwe_spec.rb +47 -0
- data/spec/models/dependency_metrics_spec.rb +125 -0
- data/spec/models/dependency_request_spec.rb +53 -0
- data/spec/models/dependency_spec.rb +71 -0
- data/spec/models/finding_spec.rb +59 -0
- data/spec/models/form_data_body_part_spec.rb +107 -0
- data/spec/models/form_data_content_disposition_spec.rb +83 -0
- data/spec/models/form_data_multi_part_spec.rb +95 -0
- data/spec/models/framework_spec.rb +59 -0
- data/spec/models/identifiable_object_spec.rb +41 -0
- data/spec/models/ldap_user_spec.rb +65 -0
- data/spec/models/license_spec.rb +101 -0
- data/spec/models/managed_user_spec.rb +101 -0
- data/spec/models/mapped_ldap_group_request_spec.rb +47 -0
- data/spec/models/mapped_ldap_group_spec.rb +47 -0
- data/spec/models/media_type_spec.rb +65 -0
- data/spec/models/multi_part_spec.rb +89 -0
- data/spec/models/notification_publisher_spec.rb +77 -0
- data/spec/models/notification_rule_spec.rb +107 -0
- data/spec/models/package_url_spec.rb +77 -0
- data/spec/models/parameterized_header_spec.rb +47 -0
- data/spec/models/permission_spec.rb +47 -0
- data/spec/models/portfolio_metrics_spec.rb +149 -0
- data/spec/models/project_metrics_spec.rb +131 -0
- data/spec/models/project_property_spec.rb +75 -0
- data/spec/models/project_spec.rb +119 -0
- data/spec/models/repository_meta_component_spec.rb +75 -0
- data/spec/models/repository_spec.rb +81 -0
- data/spec/models/score_spec.rb +59 -0
- data/spec/models/search_result_spec.rb +41 -0
- data/spec/models/tag_spec.rb +47 -0
- data/spec/models/team_spec.rb +77 -0
- data/spec/models/user_principal_spec.rb +71 -0
- data/spec/models/vulnerability_metrics_spec.rb +59 -0
- data/spec/models/vulnerability_spec.rb +201 -0
- data/spec/models/vulnerable_software_spec.rb +197 -0
- data/spec/spec_helper.rb +111 -0
- data/tmp/tmp.rb +11 -0
- metadata +402 -0
@@ -0,0 +1,109 @@
|
|
1
|
+
=begin
|
2
|
+
#Dependency-Track API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.8.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
# Common files
|
14
|
+
require 'dependency-tracker-client/api_client'
|
15
|
+
require 'dependency-tracker-client/api_error'
|
16
|
+
require 'dependency-tracker-client/version'
|
17
|
+
require 'dependency-tracker-client/configuration'
|
18
|
+
|
19
|
+
# Models
|
20
|
+
require 'dependency-tracker-client/models/about'
|
21
|
+
require 'dependency-tracker-client/models/analysis'
|
22
|
+
require 'dependency-tracker-client/models/analysis_comment'
|
23
|
+
require 'dependency-tracker-client/models/analysis_request'
|
24
|
+
require 'dependency-tracker-client/models/api_key'
|
25
|
+
require 'dependency-tracker-client/models/body_part'
|
26
|
+
require 'dependency-tracker-client/models/bom_submit_request'
|
27
|
+
require 'dependency-tracker-client/models/clone_project_request'
|
28
|
+
require 'dependency-tracker-client/models/component'
|
29
|
+
require 'dependency-tracker-client/models/component_metrics'
|
30
|
+
require 'dependency-tracker-client/models/config_property'
|
31
|
+
require 'dependency-tracker-client/models/content_disposition'
|
32
|
+
require 'dependency-tracker-client/models/cwe'
|
33
|
+
require 'dependency-tracker-client/models/dependency'
|
34
|
+
require 'dependency-tracker-client/models/dependency_metrics'
|
35
|
+
require 'dependency-tracker-client/models/dependency_request'
|
36
|
+
require 'dependency-tracker-client/models/finding'
|
37
|
+
require 'dependency-tracker-client/models/form_data_body_part'
|
38
|
+
require 'dependency-tracker-client/models/form_data_content_disposition'
|
39
|
+
require 'dependency-tracker-client/models/form_data_multi_part'
|
40
|
+
require 'dependency-tracker-client/models/framework'
|
41
|
+
require 'dependency-tracker-client/models/identifiable_object'
|
42
|
+
require 'dependency-tracker-client/models/ldap_user'
|
43
|
+
require 'dependency-tracker-client/models/license'
|
44
|
+
require 'dependency-tracker-client/models/managed_user'
|
45
|
+
require 'dependency-tracker-client/models/mapped_ldap_group'
|
46
|
+
require 'dependency-tracker-client/models/mapped_ldap_group_request'
|
47
|
+
require 'dependency-tracker-client/models/media_type'
|
48
|
+
require 'dependency-tracker-client/models/multi_part'
|
49
|
+
require 'dependency-tracker-client/models/notification_publisher'
|
50
|
+
require 'dependency-tracker-client/models/notification_rule'
|
51
|
+
require 'dependency-tracker-client/models/package_url'
|
52
|
+
require 'dependency-tracker-client/models/parameterized_header'
|
53
|
+
require 'dependency-tracker-client/models/permission'
|
54
|
+
require 'dependency-tracker-client/models/portfolio_metrics'
|
55
|
+
require 'dependency-tracker-client/models/project'
|
56
|
+
require 'dependency-tracker-client/models/project_metrics'
|
57
|
+
require 'dependency-tracker-client/models/project_property'
|
58
|
+
require 'dependency-tracker-client/models/repository'
|
59
|
+
require 'dependency-tracker-client/models/repository_meta_component'
|
60
|
+
require 'dependency-tracker-client/models/score'
|
61
|
+
require 'dependency-tracker-client/models/search_result'
|
62
|
+
require 'dependency-tracker-client/models/tag'
|
63
|
+
require 'dependency-tracker-client/models/team'
|
64
|
+
require 'dependency-tracker-client/models/user_principal'
|
65
|
+
require 'dependency-tracker-client/models/vulnerability'
|
66
|
+
require 'dependency-tracker-client/models/vulnerability_metrics'
|
67
|
+
require 'dependency-tracker-client/models/vulnerable_software'
|
68
|
+
|
69
|
+
# APIs
|
70
|
+
require 'dependency-tracker-client/api/analysis_api'
|
71
|
+
require 'dependency-tracker-client/api/badge_api'
|
72
|
+
require 'dependency-tracker-client/api/bom_api'
|
73
|
+
require 'dependency-tracker-client/api/calculator_api'
|
74
|
+
require 'dependency-tracker-client/api/component_api'
|
75
|
+
require 'dependency-tracker-client/api/config_property_api'
|
76
|
+
require 'dependency-tracker-client/api/cwe_api'
|
77
|
+
require 'dependency-tracker-client/api/default_api'
|
78
|
+
require 'dependency-tracker-client/api/dependency_api'
|
79
|
+
require 'dependency-tracker-client/api/finding_api'
|
80
|
+
require 'dependency-tracker-client/api/ldap_api'
|
81
|
+
require 'dependency-tracker-client/api/license_api'
|
82
|
+
require 'dependency-tracker-client/api/metrics_api'
|
83
|
+
require 'dependency-tracker-client/api/permission_api'
|
84
|
+
require 'dependency-tracker-client/api/project_api'
|
85
|
+
require 'dependency-tracker-client/api/project_property_api'
|
86
|
+
require 'dependency-tracker-client/api/repository_api'
|
87
|
+
require 'dependency-tracker-client/api/search_api'
|
88
|
+
require 'dependency-tracker-client/api/team_api'
|
89
|
+
require 'dependency-tracker-client/api/user_api'
|
90
|
+
require 'dependency-tracker-client/api/version_api'
|
91
|
+
require 'dependency-tracker-client/api/vulnerability_api'
|
92
|
+
|
93
|
+
module DependencyTracker
|
94
|
+
class << self
|
95
|
+
# Customize default settings for the SDK using block.
|
96
|
+
# DependencyTracker.configure do |config|
|
97
|
+
# config.username = "xxx"
|
98
|
+
# config.password = "xxx"
|
99
|
+
# end
|
100
|
+
# If no block given, return the default Configuration object.
|
101
|
+
def configure
|
102
|
+
if block_given?
|
103
|
+
yield(Configuration.default)
|
104
|
+
else
|
105
|
+
Configuration.default
|
106
|
+
end
|
107
|
+
end
|
108
|
+
end
|
109
|
+
end
|
Binary file
|
@@ -0,0 +1,70 @@
|
|
1
|
+
=begin
|
2
|
+
#Dependency-Track API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.8.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for DependencyTacker::AnalysisApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'AnalysisApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = DependencyTacker::AnalysisApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of AnalysisApi' do
|
30
|
+
it 'should create an instance of AnalysisApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(DependencyTacker::AnalysisApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for retrieve_analysis
|
36
|
+
# Retrieves an analysis trail
|
37
|
+
# @param component The UUID of the component
|
38
|
+
# @param vulnerability The UUID of the vulnerability
|
39
|
+
# @param [Hash] opts the optional parameters
|
40
|
+
# @option opts [String] :project The UUID of the project
|
41
|
+
# @return [Analysis]
|
42
|
+
describe 'retrieve_analysis test' do
|
43
|
+
it 'should work' do
|
44
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
# unit tests for update_analysis
|
49
|
+
# Records an analysis decision
|
50
|
+
# @param [Hash] opts the optional parameters
|
51
|
+
# @option opts [AnalysisRequest] :body
|
52
|
+
# @return [Analysis]
|
53
|
+
describe 'update_analysis test' do
|
54
|
+
it 'should work' do
|
55
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
# unit tests for update_global_analysis
|
60
|
+
# Records an analysis decision
|
61
|
+
# @param [Hash] opts the optional parameters
|
62
|
+
# @option opts [AnalysisRequest] :body
|
63
|
+
# @return [Analysis]
|
64
|
+
describe 'update_global_analysis test' do
|
65
|
+
it 'should work' do
|
66
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
end
|
@@ -0,0 +1,58 @@
|
|
1
|
+
=begin
|
2
|
+
#Dependency-Track API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.8.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for DependencyTacker::BadgeApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'BadgeApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = DependencyTacker::BadgeApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of BadgeApi' do
|
30
|
+
it 'should create an instance of BadgeApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(DependencyTacker::BadgeApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for get_project_vulnerabilities_badge
|
36
|
+
# Returns current metrics for a specific project
|
37
|
+
# @param name The name of the project to query on
|
38
|
+
# @param version The version of the project to query on
|
39
|
+
# @param [Hash] opts the optional parameters
|
40
|
+
# @return [ProjectMetrics]
|
41
|
+
describe 'get_project_vulnerabilities_badge test' do
|
42
|
+
it 'should work' do
|
43
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
# unit tests for get_project_vulnerabilities_badge1
|
48
|
+
# Returns current metrics for a specific project
|
49
|
+
# @param uuid The UUID of the project to retrieve metrics for
|
50
|
+
# @param [Hash] opts the optional parameters
|
51
|
+
# @return [ProjectMetrics]
|
52
|
+
describe 'get_project_vulnerabilities_badge1 test' do
|
53
|
+
it 'should work' do
|
54
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
55
|
+
end
|
56
|
+
end
|
57
|
+
|
58
|
+
end
|
@@ -0,0 +1,106 @@
|
|
1
|
+
=begin
|
2
|
+
#Dependency-Track API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.8.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for DependencyTacker::BomApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'BomApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = DependencyTacker::BomApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of BomApi' do
|
30
|
+
it 'should create an instance of BomApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(DependencyTacker::BomApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for export_component_as_cyclone_dx
|
36
|
+
# Returns dependency metadata for a specific component in CycloneDX format
|
37
|
+
# @param uuid The UUID of the project to export
|
38
|
+
# @param [Hash] opts the optional parameters
|
39
|
+
# @return [String]
|
40
|
+
describe 'export_component_as_cyclone_dx test' do
|
41
|
+
it 'should work' do
|
42
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
# unit tests for export_components_as_cyclone_dx
|
47
|
+
# Returns dependency metadata for all components in CycloneDX format
|
48
|
+
# @param [Hash] opts the optional parameters
|
49
|
+
# @return [String]
|
50
|
+
describe 'export_components_as_cyclone_dx test' do
|
51
|
+
it 'should work' do
|
52
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
53
|
+
end
|
54
|
+
end
|
55
|
+
|
56
|
+
# unit tests for export_project_as_cyclone_dx
|
57
|
+
# Returns dependency metadata for a project in CycloneDX format
|
58
|
+
# @param uuid The UUID of the project to export
|
59
|
+
# @param [Hash] opts the optional parameters
|
60
|
+
# @return [String]
|
61
|
+
describe 'export_project_as_cyclone_dx test' do
|
62
|
+
it 'should work' do
|
63
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
64
|
+
end
|
65
|
+
end
|
66
|
+
|
67
|
+
# unit tests for is_token_being_processed
|
68
|
+
# Determines if there are any tasks associated with the token that are being processed, or in the queue to be processed.
|
69
|
+
# This endpoint is intended to be used in conjunction with uploading a supported BOM document. Upon upload, a token will be returned. The token can then be queried using this endpoint to determine if any tasks (such as vulnerability analysis) is being performed on the BOM. A value of true indicates processing is occurring. A value of false indicates that no processing is occurring for the specified token. However, a value of false also does not confirm the token is valid, only that no processing is associated with the specified token.
|
70
|
+
# @param uuid The UUID of the token to query
|
71
|
+
# @param [Hash] opts the optional parameters
|
72
|
+
# @return [nil]
|
73
|
+
describe 'is_token_being_processed test' do
|
74
|
+
it 'should work' do
|
75
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
76
|
+
end
|
77
|
+
end
|
78
|
+
|
79
|
+
# unit tests for upload_bom
|
80
|
+
# Upload a supported bill of material format document
|
81
|
+
# Expects CycloneDX or SPDX (text or RDF) along and a valid project UUID. If a UUID is not specified, than the projectName and projectVersion must be specified. Optionally, if autoCreate is specified and 'true' and the project does not exist, the project will be created. In this scenario, the principal making the request will additionally need the PORTFOLIO_MANAGEMENT or PROJECT_CREATION_UPLOAD permission.
|
82
|
+
# @param [Hash] opts the optional parameters
|
83
|
+
# @option opts [String] :project
|
84
|
+
# @option opts [Boolean] :auto_create
|
85
|
+
# @option opts [String] :project_name
|
86
|
+
# @option opts [String] :project_version
|
87
|
+
# @return [nil]
|
88
|
+
describe 'upload_bom test' do
|
89
|
+
it 'should work' do
|
90
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
91
|
+
end
|
92
|
+
end
|
93
|
+
|
94
|
+
# unit tests for upload_bom1
|
95
|
+
# Upload a supported bill of material format document
|
96
|
+
# Expects CycloneDX or SPDX (text or RDF) along and a valid project UUID. If a UUID is not specified, than the projectName and projectVersion must be specified. Optionally, if autoCreate is specified and 'true' and the project does not exist, the project will be created. In this scenario, the principal making the request will additionally need the PORTFOLIO_MANAGEMENT or PROJECT_CREATION_UPLOAD permission.
|
97
|
+
# @param [Hash] opts the optional parameters
|
98
|
+
# @option opts [BomSubmitRequest] :body
|
99
|
+
# @return [nil]
|
100
|
+
describe 'upload_bom1 test' do
|
101
|
+
it 'should work' do
|
102
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
103
|
+
end
|
104
|
+
end
|
105
|
+
|
106
|
+
end
|
@@ -0,0 +1,46 @@
|
|
1
|
+
=begin
|
2
|
+
#Dependency-Track API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.8.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for DependencyTacker::CalculatorApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'CalculatorApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = DependencyTacker::CalculatorApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of CalculatorApi' do
|
30
|
+
it 'should create an instance of CalculatorApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(DependencyTacker::CalculatorApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for get_cvss_scores
|
36
|
+
# Returns the CVSS base score, impact sub-score and exploitability sub-score
|
37
|
+
# @param vector A valid CVSSv2 or CVSSv3 vector
|
38
|
+
# @param [Hash] opts the optional parameters
|
39
|
+
# @return [Score]
|
40
|
+
describe 'get_cvss_scores test' do
|
41
|
+
it 'should work' do
|
42
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
end
|
@@ -0,0 +1,110 @@
|
|
1
|
+
=begin
|
2
|
+
#Dependency-Track API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.8.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for DependencyTacker::ComponentApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'ComponentApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = DependencyTacker::ComponentApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of ComponentApi' do
|
30
|
+
it 'should create an instance of ComponentApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(DependencyTacker::ComponentApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for create_component
|
36
|
+
# Creates a new component
|
37
|
+
# @param [Hash] opts the optional parameters
|
38
|
+
# @option opts [Component] :body
|
39
|
+
# @return [Component]
|
40
|
+
describe 'create_component test' do
|
41
|
+
it 'should work' do
|
42
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
# unit tests for delete_component
|
47
|
+
# Deletes a component
|
48
|
+
# @param uuid The UUID of the component to delete
|
49
|
+
# @param [Hash] opts the optional parameters
|
50
|
+
# @return [nil]
|
51
|
+
describe 'delete_component test' do
|
52
|
+
it 'should work' do
|
53
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
57
|
+
# unit tests for get_all_components
|
58
|
+
# Returns a list of all components
|
59
|
+
# @param [Hash] opts the optional parameters
|
60
|
+
# @return [Array<Component>]
|
61
|
+
describe 'get_all_components test' do
|
62
|
+
it 'should work' do
|
63
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
64
|
+
end
|
65
|
+
end
|
66
|
+
|
67
|
+
# unit tests for get_component_by_hash
|
68
|
+
# Returns a specific component
|
69
|
+
# @param hash The MD5, SHA-1, SHA-256, SHA-512, SHA3-256, or SHA3-512 hash of the component to retrieve
|
70
|
+
# @param [Hash] opts the optional parameters
|
71
|
+
# @return [Component]
|
72
|
+
describe 'get_component_by_hash test' do
|
73
|
+
it 'should work' do
|
74
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
75
|
+
end
|
76
|
+
end
|
77
|
+
|
78
|
+
# unit tests for get_component_by_uuid
|
79
|
+
# Returns a specific component
|
80
|
+
# @param uuid The UUID of the component to retrieve
|
81
|
+
# @param [Hash] opts the optional parameters
|
82
|
+
# @return [Component]
|
83
|
+
describe 'get_component_by_uuid test' do
|
84
|
+
it 'should work' do
|
85
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
86
|
+
end
|
87
|
+
end
|
88
|
+
|
89
|
+
# unit tests for identify_internal_components
|
90
|
+
# Requests the identification of internal components in the portfolio
|
91
|
+
# @param [Hash] opts the optional parameters
|
92
|
+
# @return [nil]
|
93
|
+
describe 'identify_internal_components test' do
|
94
|
+
it 'should work' do
|
95
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
96
|
+
end
|
97
|
+
end
|
98
|
+
|
99
|
+
# unit tests for update_component
|
100
|
+
# Updates a component
|
101
|
+
# @param [Hash] opts the optional parameters
|
102
|
+
# @option opts [Component] :body
|
103
|
+
# @return [Component]
|
104
|
+
describe 'update_component test' do
|
105
|
+
it 'should work' do
|
106
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
107
|
+
end
|
108
|
+
end
|
109
|
+
|
110
|
+
end
|
@@ -0,0 +1,67 @@
|
|
1
|
+
=begin
|
2
|
+
#Dependency-Track API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.8.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for DependencyTacker::ConfigPropertyApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'ConfigPropertyApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = DependencyTacker::ConfigPropertyApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of ConfigPropertyApi' do
|
30
|
+
it 'should create an instance of ConfigPropertyApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(DependencyTacker::ConfigPropertyApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for get_config_properties
|
36
|
+
# Returns a list of all ConfigProperties for the specified groupName
|
37
|
+
# @param [Hash] opts the optional parameters
|
38
|
+
# @return [Array<ConfigProperty>]
|
39
|
+
describe 'get_config_properties test' do
|
40
|
+
it 'should work' do
|
41
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
42
|
+
end
|
43
|
+
end
|
44
|
+
|
45
|
+
# unit tests for update_config_property
|
46
|
+
# Updates a config property
|
47
|
+
# @param [Hash] opts the optional parameters
|
48
|
+
# @option opts [ConfigProperty] :body
|
49
|
+
# @return [ConfigProperty]
|
50
|
+
describe 'update_config_property test' do
|
51
|
+
it 'should work' do
|
52
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
53
|
+
end
|
54
|
+
end
|
55
|
+
|
56
|
+
# unit tests for update_config_property1
|
57
|
+
# Updates an array of config properties
|
58
|
+
# @param [Hash] opts the optional parameters
|
59
|
+
# @option opts [Array<ConfigProperty>] :body
|
60
|
+
# @return [Array<ConfigProperty>]
|
61
|
+
describe 'update_config_property1 test' do
|
62
|
+
it 'should work' do
|
63
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
64
|
+
end
|
65
|
+
end
|
66
|
+
|
67
|
+
end
|
@@ -0,0 +1,56 @@
|
|
1
|
+
=begin
|
2
|
+
#Dependency-Track API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.8.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for DependencyTacker::CweApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'CweApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = DependencyTacker::CweApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of CweApi' do
|
30
|
+
it 'should create an instance of CweApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(DependencyTacker::CweApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for get_cwe
|
36
|
+
# Returns a specific CWE
|
37
|
+
# @param cwe_id The CWE ID of the CWE to retrieve
|
38
|
+
# @param [Hash] opts the optional parameters
|
39
|
+
# @return [Cwe]
|
40
|
+
describe 'get_cwe test' do
|
41
|
+
it 'should work' do
|
42
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
# unit tests for get_cwes
|
47
|
+
# Returns a list of all CWEs
|
48
|
+
# @param [Hash] opts the optional parameters
|
49
|
+
# @return [Array<Cwe>]
|
50
|
+
describe 'get_cwes test' do
|
51
|
+
it 'should work' do
|
52
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
53
|
+
end
|
54
|
+
end
|
55
|
+
|
56
|
+
end
|