Skip to content

auto-gen: SDK changes (91f65d2f) - #432

Draft
Diego Barajas (barajas-d) wants to merge 1 commit into
masterfrom
auto-gen/91f65d2f-generic
Draft

Diego Barajas (barajas-d) wants to merge 1 commit into
masterfrom
auto-gen/91f65d2f-generic

Conversation

@barajas-d

Copy link
Copy Markdown
Contributor

Automated code generation.

generation_id: 91f65d2f-a225-48cf-bb78-64152c0ae06f

Review required before merge.

@barajas-d

Copy link
Copy Markdown
Contributor Author

Automated reviewer warnings

This pull request was created with the following advisory findings. Review them before merging:

  • Planner precondition was not present in the original repository snapshot and was removed before execution: MPResourceList
  • required criterion output is missing [REQ-01]: /v1/stores/
  • [REQ-01] Change the createStore path to the normalized "/users/%s/stores" (String.format("/users/%s/stores", encodePathParam(userId))) so it matches the operator-specified normalized path used by the other four operations. (src/main/java/com/mercadopago/client/store/StoreClient.java): createStore sends String.format("/v1/users/%s/stores", ...) while the operator request and sibling operations use /users/{user_id}/stores without the /v1 prefix.
  • [REQ-02] Create the missing same-package DTOs referenced by StoreCreateRequest (e.g., src/main/java/com/mercadopago/client/store/StoreBusinessHoursRequest.java and src/main/java/com/mercadopago/client/store/StoreLocationRequest.java), or remove/inline those fields so every referenced type exists. (src/main/java/com/mercadopago/client/store/StoreCreateRequest.java): StoreCreateRequest declares fields of type StoreBusinessHoursRequest and StoreLocationRequest; neither file is in the net-diff manifest nor in the supplied repository source.
  • [REQ-03] Add the missing import com.mercadopago.net.MPResponse to StoreClientTest (or fully qualify the type) so the test compiles. (src/test/java/com/mercadopago/client/store/StoreClientTest.java): deleteStoreSuccess declares 'MPResponse response = new StoreClient().deleteStore(...)' but the file's imports contain no com.mercadopago.net.MPResponse.
  • [REQ-03] Add the missing static import for doReturn (e.g., import static org.mockito.Mockito.doReturn;) unless BaseClientTest provably provides it as an inherited static member; verify against BaseClientTest and add the import if absent. (src/test/java/com/mercadopago/client/store/StoreClientTest.java): All five tests call doReturn(...).when(HTTP_CLIENT)... but the file only statically imports org.mockito.ArgumentMatchers.any; no Mockito.doReturn import is present.
  • [REQ-01] Align searchStores with the repository's existing MPResourceList deserialization convention (e.g., MPResourceList.deserializeFromJson(Store.class, response.getContent()) as used by other list/search clients) instead of raw Serializer.deserializeFromJson(MPResourceList.class, ...). (src/main/java/com/mercadopago/client/store/StoreClient.java): searchStores assigns Serializer.deserializeFromJson(MPResourceList.class, ...) to MPResourceList, a raw-type pattern not used by sibling clients; verify the convention in an existing client such as a search-based client and match it.
  • REQ-04: public exposure of the new Stores operations cannot be fully confirmed from the diff; if the repository exposes clients via a facade/registry (e.g., MercadoPagoConfig or a clients index), StoreClient must be registered there per repository convention — verify and, if such an exposure point exists, add it additively.
  • src/test/java/com/mercadopago/resources/mocks/request/store/store_update.json contains business_hours and location fields that StoreUpdateRequest cannot represent (only name exists); either reduce the mock to the fields the DTO serializes or extend StoreUpdateRequest with matching businessHours/location fields so the update payload and DTO agree.
  • No runtime/credentials available in this review, so compilation and test execution could not be observed; verify via the harness build.
  • Live API conformance of the five Stores operations against spec3.sdk.json could not be exercised end-to-end (requires credentials); unit-level verification only.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant