Class: Openlayer::Resources::Projects::Tests
- Inherits:
-
Object
- Object
- Openlayer::Resources::Projects::Tests
- Defined in:
- lib/openlayer/resources/projects/tests.rb
Instance Method Summary collapse
-
#create(project_id, description:, name:, subtype:, thresholds:, type:, archived: nil, default_to_all_pipelines: nil, delay_window: nil, evaluation_window: nil, exclude_pipelines: nil, include_historical_data: nil, include_pipelines: nil, uses_ml_model: nil, uses_production_data: nil, uses_reference_dataset: nil, uses_training_dataset: nil, uses_validation_dataset: nil, request_options: {}) ⇒ Openlayer::Models::Projects::TestCreateResponse
Some parameter documentations has been truncated, see Models::Projects::TestCreateParams for more details.
-
#initialize(client:) ⇒ Tests
constructor
private
A new instance of Tests.
-
#list(project_id, include_archived: nil, origin_version_id: nil, page: nil, per_page: nil, suggested: nil, type: nil, uses_production_data: nil, request_options: {}) ⇒ Openlayer::Models::Projects::TestListResponse
Some parameter documentations has been truncated, see Models::Projects::TestListParams for more details.
-
#update(project_id, payloads:, request_options: {}) ⇒ Openlayer::Models::Projects::TestUpdateResponse
Update tests.
Constructor Details
#initialize(client:) ⇒ Tests
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Tests.
138 139 140 |
# File 'lib/openlayer/resources/projects/tests.rb', line 138 def initialize(client:) @client = client end |
Instance Method Details
#create(project_id, description:, name:, subtype:, thresholds:, type:, archived: nil, default_to_all_pipelines: nil, delay_window: nil, evaluation_window: nil, exclude_pipelines: nil, include_historical_data: nil, include_pipelines: nil, uses_ml_model: nil, uses_production_data: nil, uses_reference_dataset: nil, uses_training_dataset: nil, uses_validation_dataset: nil, request_options: {}) ⇒ Openlayer::Models::Projects::TestCreateResponse
Some parameter documentations has been truncated, see Models::Projects::TestCreateParams for more details.
Create a test.
55 56 57 58 59 60 61 62 63 64 |
# File 'lib/openlayer/resources/projects/tests.rb', line 55 def create(project_id, params) parsed, = Openlayer::Projects::TestCreateParams.dump_request(params) @client.request( method: :post, path: ["projects/%1$s/tests", project_id], body: parsed, model: Openlayer::Models::Projects::TestCreateResponse, options: ) end |
#list(project_id, include_archived: nil, origin_version_id: nil, page: nil, per_page: nil, suggested: nil, type: nil, uses_production_data: nil, request_options: {}) ⇒ Openlayer::Models::Projects::TestListResponse
Some parameter documentations has been truncated, see Models::Projects::TestListParams for more details.
List tests under a project.
118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 |
# File 'lib/openlayer/resources/projects/tests.rb', line 118 def list(project_id, params = {}) parsed, = Openlayer::Projects::TestListParams.dump_request(params) query = Openlayer::Internal::Util.encode_query_params(parsed) @client.request( method: :get, path: ["projects/%1$s/tests", project_id], query: query.transform_keys( include_archived: "includeArchived", origin_version_id: "originVersionId", per_page: "perPage", uses_production_data: "usesProductionData" ), model: Openlayer::Models::Projects::TestListResponse, options: ) end |
#update(project_id, payloads:, request_options: {}) ⇒ Openlayer::Models::Projects::TestUpdateResponse
Update tests.
79 80 81 82 83 84 85 86 87 88 |
# File 'lib/openlayer/resources/projects/tests.rb', line 79 def update(project_id, params) parsed, = Openlayer::Projects::TestUpdateParams.dump_request(params) @client.request( method: :put, path: ["projects/%1$s/tests", project_id], body: parsed, model: Openlayer::Models::Projects::TestUpdateResponse, options: ) end |