#include #include #include namespace lcamera_dev { namespace { TEST(LocationPropertyToLabelTest, MapsKnownLocations) { using namespace libcamera::properties; EXPECT_EQ(locationPropertyToLabel(CameraLocationFront), "front"); EXPECT_EQ(locationPropertyToLabel(CameraLocationBack), "back"); EXPECT_EQ(locationPropertyToLabel(CameraLocationExternal), "external"); } TEST(LocationPropertyToLabelTest, UnknownLocationReturnsEmptyString) { EXPECT_EQ(locationPropertyToLabel(-1), ""); EXPECT_EQ(locationPropertyToLabel(99), ""); } } // namespace } // namespace lcamera_dev