lidavidm commented on a change in pull request #11579:
URL: https://github.com/apache/arrow/pull/11579#discussion_r756051247



##########
File path: cpp/src/arrow/compute/exec/hash_join_node_test.cc
##########
@@ -382,19 +382,24 @@ struct RandomDataTypeVector {
     data_types.push_back(RandomDataType::Random(rng, constraints));
   }
 
+  std::string DataTypeToString(size_t i) {
+    std::stringstream ss;
+
+    if (!data_types[i].is_fixed_length) {
+      ss << "str[" << data_types[i].min_string_length << ".."
+         << data_types[i].max_string_length << "]";
+    } else {
+      ss << "int[" << data_types[i].fixed_length << "]";
+    }
+    return ss.str();
+  }
+
   void Print() {

Review comment:
       Sorry - a few things:
   - Both DataTypeToString and Print are unused.
   - SCOPED_TRACE doesn't replace printing; instead inside the scope it's 
declared/until it's dropped, any test failure will include the string passed to 
it. So it doesn't make sense to use standalone here. Instead you'd probably 
have something like `SCOPED_TRACE(Print())` (assuming Print() returns 
std::string instead of printing) down below in an appropriate location.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to