ARROW-17686: [C++] Add custom ToPrint to AsofJoinBasicTest (#14172)
ARROW-17686: [C++] Add custom ToPrint to AsofJoinBasicTest (#14172)

Add a simple printer compatible with [gtest printers](https://github.com/google/googletest/blob/main/googletest/include/gtest/gtest-printers.h), hopefully this will solve some issues with valgrind (3.13.0) on ubuntu 18.04 running the unit test `arrow-compute-asof-join-node-test`.

Jira ticket: https://issues.apache.org/jira/browse/ARROW-17686

Authored-by: Percy Camilo Triveño Aucahuasi <55de299e1e0d040dacf8be5f1cc57e2b59244f29@gmail.com>
Signed-off-by: Antoine Pitrou <9359a4d812173b65a3a0094cd86363e79731a3c2@python.org>
apache/arrow,icexelloss/arrow,kou/arrow,icexelloss/arrow,apache/arrow,icexelloss/arrow,kou/arrow,apache/arrow,icexelloss/arrow,kou/arrow,icexelloss/arrow,kou/arrow,icexelloss/arrow,kou/arrow,icexelloss/arrow,apache/arrow,icexelloss/arrow,apache/arrow,icexelloss/arrow,icexelloss/arrow,apache/arrow,kou/arrow,icexelloss/arrow,apache/arrow,kou/arrow,icexelloss/arrow,apache/arrow,kou/arrow,kou/arrow,icexelloss/arrow,kou/arrow,apache/arrow,apache/arrow,apache/arrow,apache/arrow,kou/arrow,kou/arrow,kou/arrow,apache/arrow,kou/arrow,apache/arrow,icexelloss/arrow