File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
webmagic-saxon/src/test/java/us/codecraft/webmagic/selector Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change 88import org .junit .Assert ;
99import org .junit .Ignore ;
1010import org .junit .Test ;
11+
1112import us .codecraft .xsoup .XPathEvaluator ;
1213import us .codecraft .xsoup .Xsoup ;
1314
@@ -1368,7 +1369,7 @@ public void testXPath2() {
13681369 String text = "<h1>眉山:扎实推进农业农村工作 促农持续增收<br>\n " +
13691370 "<span>2013-07-31 23:29:45 来源:<a href=\" http://www.mshw.net\" target=\" _blank\" style=\" color:#AAA\" >眉山网</a> 责任编辑:张斯炜</span></h1>" ;
13701371 XpathSelector xpathSelector = new XpathSelector ("//h1/text()" );
1371- System . out . println ( xpathSelector .select (text ));
1372+ Assert . assertEquals ( "眉山:扎实推进农业农村工作 促农持续增收 " , xpathSelector .select (text ));
13721373 }
13731374
13741375 @ Test
You can’t perform that action at this time.
0 commit comments