aboutsummaryrefslogtreecommitdiff
path: root/tests/print-to.h
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2015-06-17 23:52:52 -0500
committerCharles Kerr <charles.kerr@canonical.com>2015-06-17 23:52:52 -0500
commit25c99926957688340d794a92f4b47632943f6901 (patch)
treee6361ed12e28927d1e5ebd5fe36b280be10ae2e0 /tests/print-to.h
parent3c85ae61b63c484d8465468c07860fc332ca5072 (diff)
downloadayatana-indicator-datetime-25c99926957688340d794a92f4b47632943f6901.tar.gz
ayatana-indicator-datetime-25c99926957688340d794a92f4b47632943f6901.tar.bz2
ayatana-indicator-datetime-25c99926957688340d794a92f4b47632943f6901.zip
add (failing) regression test for x-canonical-alarm components whose valarms have no triggers
Diffstat (limited to 'tests/print-to.h')
-rw-r--r--tests/print-to.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/print-to.h b/tests/print-to.h
index f4af2f7..357925f 100644
--- a/tests/print-to.h
+++ b/tests/print-to.h
@@ -47,6 +47,30 @@ PrintTo(const Alarm& alarm, std::ostream* os)
*os << '}';
}
+void
+PrintTo(const Appointment& appointment, std::ostream* os)
+{
+ *os << '{';
+
+ *os << "{uid:'" << appointment.uid << "'}"
+ << "{color:'" << appointment.color << "'}"
+ << "{summary:'" << appointment.summary << "'}"
+ << "{activation_url:'" << appointment.activation_url << "'}";
+
+ *os << "{begin:";
+ PrintTo(appointment.begin, os);
+ *os << '}';
+
+ *os << "{end:";
+ PrintTo(appointment.end, os);
+ *os << '}';
+
+ for(const auto& alarm : appointment.alarms)
+ PrintTo(alarm, os);
+
+ *os << '}';
+}
+
} // namespace datetime
} // namespace indicator
} // namespace unity