Skip to content
This repository was archived by the owner on Sep 26, 2023. It is now read-only.

Commit b629488

Browse files
authored
fix: revert generics syntax change in MockHttpService test utility (#1574)
* fix: revert generic change in method signature of MockHttpService
1 parent 6e12445 commit b629488

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

gax-httpjson/src/main/java/com/google/api/gax/httpjson/longrunning/stub/HttpJsonOperationsStub.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,8 +297,8 @@ protected HttpJsonOperationsStub(
297297
}
298298

299299
@InternalApi
300-
public static List<ApiMethodDescriptor<?, ?>> getMethodDescriptors() {
301-
List<ApiMethodDescriptor<?, ?>> methodDescriptors = new ArrayList<>();
300+
public static List<ApiMethodDescriptor> getMethodDescriptors() {
301+
List<ApiMethodDescriptor> methodDescriptors = new ArrayList<>();
302302
methodDescriptors.add(listOperationsMethodDescriptor);
303303
methodDescriptors.add(getOperationMethodDescriptor);
304304
methodDescriptors.add(deleteOperationMethodDescriptor);

gax-httpjson/src/test/java/com/google/api/gax/httpjson/MockHttpServiceTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ public PathTemplate getPathTemplate() {
143143
.setResponseParser(PET_RESPONSE_PARSER)
144144
.build();
145145

146-
private static final List<ApiMethodDescriptor<?, ?>> SERVER_METHOD_DESCRIPTORS =
146+
private static final List<ApiMethodDescriptor> SERVER_METHOD_DESCRIPTORS =
147147
Lists.newArrayList(methodDescriptor);
148148

149149
private static MockHttpService testService =

gax-httpjson/src/test/java/com/google/api/gax/httpjson/testing/MockHttpService.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public final class MockHttpService extends MockHttpTransport {
5555
private final Multimap<String, String> requestHeaders = LinkedListMultimap.create();
5656
private final List<String> requestPaths = new LinkedList<>();
5757
private final Queue<HttpResponseFactory> responseHandlers = new LinkedList<>();
58-
private List<ApiMethodDescriptor<?, ?>> serviceMethodDescriptors;
58+
private List<ApiMethodDescriptor> serviceMethodDescriptors;
5959
private String endpoint;
6060

6161
/**
@@ -66,8 +66,7 @@ public final class MockHttpService extends MockHttpTransport {
6666
* @param pathPrefix - the fixed portion of the endpoint URL that prefixes the methods' path
6767
* template substring.
6868
*/
69-
public MockHttpService(
70-
List<ApiMethodDescriptor<?, ?>> serviceMethodDescriptors, String pathPrefix) {
69+
public MockHttpService(List<ApiMethodDescriptor> serviceMethodDescriptors, String pathPrefix) {
7170
this.serviceMethodDescriptors = ImmutableList.copyOf(serviceMethodDescriptors);
7271
endpoint = pathPrefix;
7372
}

0 commit comments

Comments
 (0)