This source file includes following definitions.
- TEST
#include "dbus/string_util.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace dbus {
TEST(StringUtilTest, IsValidObjectPath) {
EXPECT_TRUE(IsValidObjectPath("/"));
EXPECT_TRUE(IsValidObjectPath("/foo/bar"));
EXPECT_TRUE(IsValidObjectPath("/hoge_fuga/piyo123"));
EXPECT_FALSE(IsValidObjectPath(std::string()));
EXPECT_FALSE(IsValidObjectPath("//"));
EXPECT_FALSE(IsValidObjectPath("/foo//bar"));
EXPECT_FALSE(IsValidObjectPath("/foo///bar"));
EXPECT_FALSE(IsValidObjectPath("/foo/"));
EXPECT_FALSE(IsValidObjectPath("/foo/bar/"));
EXPECT_FALSE(IsValidObjectPath("foo/bar"));
EXPECT_FALSE(IsValidObjectPath("/foo.bar"));
EXPECT_FALSE(IsValidObjectPath("/foo/*"));
EXPECT_FALSE(IsValidObjectPath("/foo/bar(1)"));
}
}