Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
3 changes: 2 additions & 1 deletion src/ur/dashboard_client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,8 @@ bool DashboardClient::commandQuit()
bool DashboardClient::commandRunning()
{
assertVersion("5.0.0", "1.6", "running");
return sendRequest("running", "Program running: true");
std::string const response = sendAndReceive("running");
return std::regex_match(response, std::regex("Program running: true"));
}

bool DashboardClient::commandIsProgramSaved()
Expand Down
2 changes: 2 additions & 0 deletions tests/test_dashboard_client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,9 @@ TEST_F(DashboardClientTest, run_program)
EXPECT_TRUE(dashboard_client_->commandPlay());
EXPECT_TRUE(dashboard_client_->commandPause());
EXPECT_TRUE(dashboard_client_->commandPlay());
EXPECT_TRUE(dashboard_client_->commandRunning());
EXPECT_TRUE(dashboard_client_->commandStop());
EXPECT_FALSE(dashboard_client_->commandRunning());
EXPECT_TRUE(dashboard_client_->commandPowerOff());
dashboard_client_->commandClosePopup(); // Necessary for CB3 test
}
Expand Down
Loading