You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ay...@apache.org on 2014/09/11 11:19:13 UTC
git commit: CAMEL-7801 add comments to the test cases
Repository: camel
Updated Branches:
refs/heads/master 2c01b8e84 -> 48f599e86
CAMEL-7801 add comments to the test cases
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/48f599e8
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/48f599e8
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/48f599e8
Branch: refs/heads/master
Commit: 48f599e862bd1e7ee1df876cfe543ec9b3d89a7d
Parents: 2c01b8e
Author: Akitoshi Yoshida <ay...@apache.org>
Authored: Thu Sep 11 11:19:10 2014 +0200
Committer: Akitoshi Yoshida <ay...@apache.org>
Committed: Thu Sep 11 11:19:10 2014 +0200
----------------------------------------------------------------------
.../XMLTokenExpressionIteratorGroupingTest.java | 14 +++++++++++---
1 file changed, 11 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/48f599e8/camel-core/src/test/java/org/apache/camel/support/XMLTokenExpressionIteratorGroupingTest.java
----------------------------------------------------------------------
diff --git a/camel-core/src/test/java/org/apache/camel/support/XMLTokenExpressionIteratorGroupingTest.java b/camel-core/src/test/java/org/apache/camel/support/XMLTokenExpressionIteratorGroupingTest.java
index 20f5d45..f0c6f11 100644
--- a/camel-core/src/test/java/org/apache/camel/support/XMLTokenExpressionIteratorGroupingTest.java
+++ b/camel-core/src/test/java/org/apache/camel/support/XMLTokenExpressionIteratorGroupingTest.java
@@ -33,6 +33,7 @@ import junit.framework.TestCase;
*/
public class XMLTokenExpressionIteratorGroupingTest extends TestCase {
+ // the input containing multiple Cs
private static final byte[] TEST_BODY = (
"<?xml version='1.0' encoding='UTF-8'?>"
+ "<g:A xmlns:g='urn:g'>"
@@ -50,6 +51,7 @@ public class XMLTokenExpressionIteratorGroupingTest extends TestCase {
+ "</c:B>"
+ "</g:A>").getBytes();
+ // one extracted C in its wrapped context per token
private static final String[] RESULTS_WRAPPED_SIZE1 = {
"<?xml version='1.0' encoding='UTF-8'?>"
+ "<g:A xmlns:g='urn:g'>"
@@ -99,7 +101,8 @@ public class XMLTokenExpressionIteratorGroupingTest extends TestCase {
+ "<c:C attr='8'/>"
+ "</c:B>"
+ "</g:A>"};
-
+
+ // two extracted Cs in their wrapped context per token
private static final String[] RESULTS_WRAPPED_SIZE2 = {
"<?xml version='1.0' encoding='UTF-8'?>"
+ "<g:A xmlns:g='urn:g'>"
@@ -129,7 +132,8 @@ public class XMLTokenExpressionIteratorGroupingTest extends TestCase {
+ "<c:C attr='8'/>"
+ "</c:B>"
+ "</g:A>"};
-
+
+ // at most three extracted Cs in their common wrapped context per token
private static final String[] RESULTS_WRAPPED_SIZE3L = {
"<?xml version='1.0' encoding='UTF-8'?>"
+ "<g:A xmlns:g='urn:g'>"
@@ -160,6 +164,7 @@ public class XMLTokenExpressionIteratorGroupingTest extends TestCase {
+ "</c:B>"
+ "</g:A>"};
+ // three extracted Cs in their corresponding wrapped contexts per token
private static final String[] RESULTS_WRAPPED_SIZE3U = {
"<?xml version='1.0' encoding='UTF-8'?>"
+ "<g:A xmlns:g='urn:g'>"
@@ -187,6 +192,7 @@ public class XMLTokenExpressionIteratorGroupingTest extends TestCase {
+ "</c:B>"
+ "</g:A>"};
+ // four extracted Cs in their wrapped context per token
private static final String[] RESULTS_WRAPPED_SIZE4 = {
"<?xml version='1.0' encoding='UTF-8'?>"
+ "<g:A xmlns:g='urn:g'>"
@@ -206,9 +212,11 @@ public class XMLTokenExpressionIteratorGroupingTest extends TestCase {
+ "<c:C attr='8'/>"
+ "</c:B>"
+ "</g:A>"};
-
+
+ // at most five extracted Cs in their common wrapped context per token
private static final String[] RESULTS_WRAPPED_SIZE5L = RESULTS_WRAPPED_SIZE4;
+ // five extracted Cs in their corresponding wrapped contexts per token
private static final String[] RESULTS_WRAPPED_SIZE5U = {
"<?xml version='1.0' encoding='UTF-8'?>"
+ "<g:A xmlns:g='urn:g'>"