Esempio n. 1
0
 public void LowerCaseElementWithChildElements()
 {
     const string pre = @"<root><child><child-of-child>FOO</child-of-child></child></root>";
     const string post = pre;
     const string xpath = "root";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 2
0
 public void LowerCaseMixedElements()
 {
     const string pre = @"<root>A<![CDATA[VALUE]]><?foo BAR?><!--COMMENT-->B</root>";
     const string post = pre;
     const string xpath = "root";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 3
0
 public void LowerCaseElementsCDataValues()
 {
     const string pre = @"<root attribute=""""><![CDATA[PRE]]></root>";
     const string post = @"<root attribute=""""><![CDATA[pre]]></root>";
     const string xpath = "root";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 4
0
 public void LowerCaseElementsValues()
 {
     const string pre = @"<root attribute="""">PRE</root>";
     const string post = @"<root attribute="""">pre</root>";
     const string xpath = "root";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 5
0
 public void LowerCaseComments()
 {
     const string pre = @"<root><!--COMMENT--></root>";
     const string post = @"<root><!--comment--></root>";
     const string xpath = "//comment()";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 6
0
 public void LowerCaseCDataSections()
 {
     const string pre = @"<root><![CDATA[SOMETHING]]></root>";
     const string post = @"<root><![CDATA[something]]></root>";
     const string xpath = "//root";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 7
0
 public void LowerCaseAttributeValues()
 {
     const string pre = @"<root attribute=""VALUE""></root>";
     const string post = @"<root attribute=""value""></root>";
     const string xpath = "root/@attribute";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 8
0
 public void LowerCaseTextNodes()
 {
     const string pre = @"<root>TEXT</root>";
     const string post = @"<root>text</root>";
     const string xpath = "//text()";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 9
0
 public void LowerCaseProcessingInstructions()
 {
     const string pre = @"<root><?foo BAR ?></root>";
     const string post = @"<root><?foo bar ?></root>";
     const string xpath = "//processing-instruction()";
     var task = new LowerCase();
     Run(pre, post, xpath, task);
 }
Esempio n. 10
0
 public void LowerCaseTextNodesWithSimpleRegularExpression()
 {
     const string pre = @"<root>ABCDEFGH</root>";
     const string post = @"<root>ABcdeFGH</root>";
     const string xpath = "//text()";
     var task = new LowerCase {Pattern = "CDE"};
     Run(pre, post, xpath, task);
 }
Esempio n. 11
0
 public void LowerCaseTextNodesWithRegularExpression()
 {
     const string pre = @"<root>TEXT TEXT</root>";
     const string post = @"<root>tEXT tEXT</root>";
     const string xpath = "//text()";
     var task = new LowerCase {Pattern = @"\b[A-Z]{1}"};
     Run(pre, post, xpath, task);
 }