17 #include <gtest/gtest.h> 21 TEST(S3CommonUtilsTest, TestGetFileNameEmptyStringReturnsEmptyString)
26 TEST(S3CommonUtilsTest, TestGetFileNameDirectoryReturnsEmptyString)
31 TEST(S3CommonUtilsTest, TestGetFileNameNoDirectoryReturnsFileName)
36 TEST(S3CommonUtilsTest, TestGetFileNameWithDirectoryReturnsFileName)
38 EXPECT_EQ(
"TestFile",
GetFileName(
"TestDir/TestFile"));
41 TEST(S3CommonUtilsTest, TestGenerateObjectKeyEmptyPrefixReturnsFileName)
46 TEST(S3CommonUtilsTest, TestGenerateObjectKeyOnlyUsesFileName)
51 TEST(S3CommonUtilsTest, TestGenerateObjectKeyInsertSlash)
56 TEST(S3CommonUtilsTest, TestGenerateObjectKeyDoesntInsertExtraSlash)
std::string GetFileName(const std::string &file_path)
std::string GenerateObjectKey(const std::string &file_path, const std::string &prefix)
TEST(S3CommonUtilsTest, TestGetFileNameEmptyStringReturnsEmptyString)