tests: diagnostics for mismatched `set` commands

I'm going via boost::core::demangle because 'a' and 'i' are type
identifiers which do not make much sense to me, and because we depend on
Boost already.

Change-Id: I151fa25df4e0b60feed3b5c7589b02d365109408
diff --git a/tests/leaf_editing.cpp b/tests/leaf_editing.cpp
index acedcd0..2db8193 100644
--- a/tests/leaf_editing.cpp
+++ b/tests/leaf_editing.cpp
@@ -7,10 +7,16 @@
 */
 
 #include "trompeloeil_doctest.h"
+#include <boost/core/demangle.hpp>
 #include "ast_commands.hpp"
 #include "parser.hpp"
 #include "static_schema.hpp"
 
+std::ostream& operator<<(std::ostream& s, const set_ cmd)
+{
+    return s << "Command SET {path: " << pathToAbsoluteSchemaString(cmd.m_path) << ", type " << boost::core::demangle(cmd.m_data.type().name()) << ", data: " << leafDataToString(cmd.m_data) << "}";
+}
+
 TEST_CASE("leaf editing")
 {
     auto schema = std::make_shared<StaticSchema>();