From cf29b4f777e6fd71220fcf4a03f1329fff9d32db Mon Sep 17 00:00:00 2001
From: ilor <kailoran@gmail.com>
Date: Thu, 12 May 2011 16:55:47 +0200
Subject: [PATCH] better failed test message when no annotation channel

---
 tests/datarule.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/datarule.cpp b/tests/datarule.cpp
index a768770..736ef8c 100644
--- a/tests/datarule.cpp
+++ b/tests/datarule.cpp
@@ -133,7 +133,7 @@ void check_sentences(int sentence_i, const Corpus2::Tagset& tagset,
 		BOOST_REQUIRE(annotated);
 		foreach (const Corpus2::AnnotatedSentence::chan_map_t::value_type& v, expected_annotated->all_channels()) {
 			std::string channel_name = v.first;
-			BOOST_REQUIRE(annotated->has_channel(channel_name));
+			BOOST_REQUIRE_MESSAGE(annotated->has_channel(channel_name), "Expected channel " + channel_name);
 			const Corpus2::AnnotationChannel& expected_channel = v.second;
 			std::string expected_channel_data = channel_name + ":" + expected_channel.dump_alpha();
 			Corpus2::AnnotationChannel& channel = annotated->get_channel(channel_name);
-- 
GitLab