Skip to content

Commit

Permalink
Fix compile
Browse files Browse the repository at this point in the history
  • Loading branch information
PHILO-HE committed Apr 8, 2024
1 parent 721ffce commit 0bec5fd
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions velox/functions/sparksql/tests/StringTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,17 @@
namespace facebook::velox::functions::sparksql::test {
namespace {

std::string generateRandomString(size_t length) {
const std::string chars =
"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";

std::string randomString;
for (std::size_t i = 0; i < length; ++i) {
randomString += chars[folly::Random::rand32() % chars.size()];
}
return randomString;
}

class StringTest : public SparkFunctionBaseTest {
protected:
// This is a five codepoint sequence that renders as a single emoji.
Expand Down

0 comments on commit 0bec5fd

Please sign in to comment.