You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
#rnx #rb none #ROBOMERGE-OWNER: ryan.durand #ROBOMERGE-AUTHOR: ryan.durand #ROBOMERGE-SOURCE: CL 10869210 via CL 10869511 via CL 10869900 #ROBOMERGE-BOT: (v613-10869866) [CL 10870549 by ryan durand in Main branch]
46 lines
1.1 KiB
C++
46 lines
1.1 KiB
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#pragma once
|
|
|
|
#include "CoreMinimal.h"
|
|
#include "Interfaces/IHttpRequest.h"
|
|
|
|
/**
|
|
* Test an Http request to a specified endpoint Url
|
|
*/
|
|
class FHttpTest
|
|
{
|
|
public:
|
|
|
|
/**
|
|
* Constructor
|
|
*
|
|
* @param Verb - verb to use for request (GET,POST,DELETE,etc)
|
|
* @param Payload - optional payload string
|
|
* @param Url - url address to connect to
|
|
* @param InIterations - total test iterations to run
|
|
*/
|
|
FHttpTest(const FString& InVerb, const FString& InPayload, const FString& InUrl, int32 InIterations);
|
|
|
|
/**
|
|
* Kick off the Http request for the test and wait for delegate to be called
|
|
*/
|
|
void Run(void);
|
|
|
|
/**
|
|
* Delegate called when the request completes
|
|
*
|
|
* @param HttpRequest - object that started/processed the request
|
|
* @param HttpResponse - optional response object if request completed
|
|
* @param bSucceeded - true if Url connection was made and response was received
|
|
*/
|
|
void RequestComplete(FHttpRequestPtr HttpRequest, FHttpResponsePtr HttpResponse, bool bSucceeded);
|
|
|
|
private:
|
|
FString Verb;
|
|
FString Payload;
|
|
FString Url;
|
|
int32 TestsToRun;
|
|
};
|
|
|