Skip to content

Commit d70157c

Browse files
[Recorder] Add return types to test/utils methods (Azure#20510)
1 parent c629e05 commit d70157c

File tree

1 file changed

+3
-3
lines changed
  • sdk/test-utils/recorder/test/utils

1 file changed

+3
-3
lines changed

sdk/test-utils/recorder/test/utils/utils.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { createPipelineRequest, HttpMethods } from "@azure/core-rest-pipeline";
1+
import { createPipelineRequest, HttpMethods, PipelineResponse } from "@azure/core-rest-pipeline";
22
import { expect } from "chai";
33
import { env } from "../../src";
44
import { isLiveMode, TestMode } from "../../src/utils/utils";
@@ -14,7 +14,7 @@ export const setTestMode = (mode: TestMode): TestMode => {
1414
* Returns the test server url
1515
* Acts as the endpoint [ Works as a substitute to the actual Azure Services ]
1616
*/
17-
export function getTestServerUrl() {
17+
export function getTestServerUrl(): string {
1818
// utils/server.ts creates a localhost server at port 8080
1919
// - In "live" mode, we are hitting directly the localhost endpoint
2020
// - In "record" and "playback" modes, we need to hit the localhost of the host network
@@ -39,7 +39,7 @@ export async function makeRequestAndVerifyResponse(
3939
method: HttpMethods;
4040
},
4141
expectedResponse: { [key: string]: unknown } | undefined
42-
) {
42+
): Promise<PipelineResponse> {
4343
const req = createPipelineRequest({
4444
url: request.url ?? getTestServerUrl() + request.path,
4545
body: request.body,

0 commit comments

Comments
 (0)