-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
created a test class header for globus api
- Loading branch information
Showing
2 changed files
with
47 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
#ifndef TESTGLOBUSAPICLIENT_HPP | ||
#define TESTGLOBUSAPICLIENT_HPP | ||
#pragma once | ||
|
||
// Local private includes | ||
#include "GlobusAPI.hpp" | ||
|
||
// Local public includes | ||
#include "common/DynaLog.hpp" | ||
#include "common/SDMS.pb.h" | ||
#include "common/libjson.hpp" | ||
|
||
// Third party includes | ||
#include <curl/curl.h> | ||
|
||
// Standard includes | ||
#include <string> | ||
#include <vector> | ||
|
||
namespace SDMS { | ||
namespace Core { | ||
|
||
class TestGlobusAPI: GlobusAPI { | ||
TestGlobusAPI(); | ||
explicit TestGlobusAPI(LogContext log_context); | ||
|
||
~TestGlobusAPI(); | ||
|
||
public: | ||
long get(CURL *a_curl, const std::string &a_base_url, | ||
const std::string &a_url_path, const std::string &a_token, | ||
const std::vector<std::pair<std::string, std::string>> &a_params, | ||
std::string &a_result); | ||
long post(CURL *a_curl, const std::string &a_base_url, | ||
const std::string &a_url_path, const std::string &a_token, | ||
const std::vector<std::pair<std::string, std::string>> &a_params, | ||
const libjson::Value *a_body, std::string &a_result); | ||
}; | ||
|
||
} // namespace Core | ||
} // namespace SDMS | ||
|
||
#endif |