From: Grant B. <gbi...@co...> - 2010-02-16 18:08:19
|
We've been using the crap out of Expressions. Basically, it's just Java code inside the tag, except a little looser. <expression><![CDATA[ import whatever; // if you need to import // notice that orders is implicitly typed // (you might still need to import the type, though) orders = component("tbleOrders"); // defined in an earlier component tag; assertEquals(0, orders.getRowCount()); ]]></expression> Always use the CDATA tag (or directive, or whatever you call it). It basically escapes everything before "]]>" so your code doesn't get mistaken for XML. The "component" function is an Abbot built-in. See http://abbot.sourceforge.net/doc/user-guide.shtml -> "Arbitrary Expressions" for other built-ins. And of course, you'll want to check out the Beanshell docs, since Beanshell is what interprets the Expression. http://www.beanshell.org/docs.html -Grant On Tue, Feb 16, 2010 at 11:20 AM, <wmo...@cs...> wrote: > Hi Abbot Users, > > I'm intrigued by the power of the Expression capability in Abbot but I > can't for the life of me figure out the syntax / usage when I try to embed > one into an XML Abbot script. Does anybody have any examples they would > share on the syntax and any caveats surrounding the expression operator? > > Thanks. great work Tim, Abbot is a great tool! > > Wayne Motycka > CS Dept. Univ of Nebraska - Lincoln > > > ------------------------------------------------------------------------------ > SOLARIS 10 is the OS for Data Centers - provides features such as DTrace, > Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW > http://p.sf.net/sfu/solaris-dev2dev > _______________________________________________ > abbot-users mailing list > abb...@li... > https://lists.sourceforge.net/lists/listinfo/abbot-users > |