Skip to content

Commit

Permalink
test_zivid_camera: Use camelCasing in CA tests
Browse files Browse the repository at this point in the history
http://wiki.ros.org/gtest recommends using camelCasing for test names.
In this file we mixed a bit between camelCasing and snake_casing. In
this commit all tests are updated to use camelCase.
  • Loading branch information
apartridge committed Jun 19, 2020
1 parent 77836d0 commit 0640ec0
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions zivid_camera/test/test_zivid_camera.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -553,12 +553,12 @@ class ZividCATest : public ZividNodeTest
std::vector<std::unique_ptr<dynamic_reconfigure::Client<zivid_camera::CaptureFrameConfig>>> m_captureFrameClients;
};

TEST_F(ZividCATest, test_ca_service_is_available)
TEST_F(ZividCATest, testCaptureAssistantServiceAvailable)
{
ASSERT_TRUE(ros::service::waitForService(capture_assistant_suggest_settings_service_name, short_wait_duration));
}

TEST_F(ZividCATest, test_different_max_capture_time_and_ambient_light_frequency)
TEST_F(ZividCATest, testDifferentMaxCaptureTimeAndAmbientLightFrequency)
{
using Request = zivid_camera::CaptureAssistantSuggestSettings::Request;
for (double max_capture_time : { 0.2, 1.2, 10.0 })
Expand All @@ -571,7 +571,7 @@ TEST_F(ZividCATest, test_different_max_capture_time_and_ambient_light_frequency)
}
}

TEST_F(ZividCATest, test_going_from_several_frames_to_1_frame)
TEST_F(ZividCATest, testGoingFromMultipleFramesTo1Frame)
{
using Request = zivid_camera::CaptureAssistantSuggestSettings::Request;
performSuggestSettingsAndCompareWithCppAPI(ros::Duration{ 10.0 }, Request::AMBIENT_LIGHT_FREQUENCY_NONE);
Expand All @@ -581,7 +581,7 @@ TEST_F(ZividCATest, test_going_from_several_frames_to_1_frame)
ASSERT_EQ(numEnabled3DFrames(), 1U);
}

TEST_F(ZividCATest, test_capture_assistant_with_invalid_max_capture_time_fails)
TEST_F(ZividCATest, testCaptureAssistantWithInvalidMaxCaptureTimeFails)
{
zivid_camera::CaptureAssistantSuggestSettings srv;
srv.request.max_capture_time = ros::Duration{ 0.0 };
Expand All @@ -598,14 +598,14 @@ TEST_F(ZividCATest, test_capture_assistant_with_invalid_max_capture_time_fails)
ASSERT_TRUE(ros::service::call(capture_assistant_suggest_settings_service_name, srv));
}

TEST_F(ZividCATest, test_capture_assistant_default_ambient_light_frequency_works)
TEST_F(ZividCATest, testCaptureAssistantDefaultAmbientLightFrequencyWorks)
{
zivid_camera::CaptureAssistantSuggestSettings srv;
srv.request.max_capture_time = ros::Duration{ 1.0 };
ASSERT_TRUE(ros::service::call(capture_assistant_suggest_settings_service_name, srv));
}

TEST_F(ZividCATest, test_capture_assistant_invalid_ambient_light_frequency_fails)
TEST_F(ZividCATest, testCaptureAssistantInvalidAmbientLightFrequencyFails)
{
zivid_camera::CaptureAssistantSuggestSettings srv;
srv.request.max_capture_time = ros::Duration{ 1.0 };
Expand Down

0 comments on commit 0640ec0

Please sign in to comment.