Skip to content

Add App Check support to Database #1260

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 18 commits into from
Apr 20, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix for unit tests
  • Loading branch information
a-maurice committed Apr 5, 2023
commit ef27c46cbb99df0d415ca28f7cf4aae6be58e652
2 changes: 1 addition & 1 deletion database/src/desktop/connection/connection.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class Connection : public WebSocketClientEventHandler {
explicit Connection(scheduler::Scheduler* scheduler, const HostInfo& info,
const char* opt_last_session_id,
ConnectionEventHandler* event_handler, Logger* logger,
const std::string& app_check_token);
const std::string& app_check_token = "");
~Connection() override;

// Connection is neither copyable nor movable.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ TEST(WebSocketClientImpl, Test1) {
TestClientEventHandler handler(&semaphore);
Logger logger(nullptr);
scheduler::Scheduler scheduler;
WebSocketClientImpl ws_client(uri.c_str(), "", &logger, &scheduler, &handler);
WebSocketClientImpl ws_client(uri.c_str(), "", &logger, &scheduler, "", &handler);

// Connect to local server
LogDebug("[Client] Connecting to %s", uri.c_str());
Expand Down Expand Up @@ -231,7 +231,7 @@ TEST(WebSocketClientImpl, Test1) {
TEST(WebSocketClientImpl, TestEdgeCase1) {
Logger logger(nullptr);
scheduler::Scheduler scheduler;
WebSocketClientImpl ws_client("ws://localhost", "", &logger, &scheduler);
WebSocketClientImpl ws_client("ws://localhost", "", &logger, &scheduler, "");
}

// Test if it is safe to connect to a server and destroy the client immediately.
Expand All @@ -249,7 +249,7 @@ TEST(WebSocketClientImpl, TestEdgeCase2) {
int count = 0;
while ((count++) < 10000) {
WebSocketClientImpl* ws_client =
new WebSocketClientImpl(uri.c_str(), "", &logger, &scheduler);
new WebSocketClientImpl(uri.c_str(), "", &logger, &scheduler, "");

// Connect to local server
LogDebug("[Client][%d] Connecting to %s", count, uri.c_str());
Expand Down