Actually, returning an error code in Java is pretty straight forward: System.exit(123); // or whatever code you want.
All you have to do is agree on the error code(s). -Rico -------- Original-Nachricht -------- > Datum: Wed, 3 Oct 2007 22:02:38 +0100 > Von: sebb <[EMAIL PROTECTED]> > An: "JMeter Users List" <[email protected]> > Betreff: Re: jmeter.bat: Special exit code when test plan run fails? > This is a problem with Java applications. > > In general it is very difficult to return a meaningful code from Java > applications. > > > On 03/10/2007, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Hi all, > > > > I was wondering if there is a special exit code for jmeter.[bat|sh] and > the like when a test fails. > > > > For example if I run this on Windows, the exit code is '0' although some > tests failed: > > > > c:\jakarta-jmeter-2.3RC4\bin>jmeter.bat -n -t ..\extras\Test.jmx -l > shorttest.log > > Created the tree successfully > > Starting the test @ Wed Oct 03 13:10:00 PDT 2007 (1191442200884) > > Tidying up ... @ Wed Oct 03 13:10:04 PDT 2007 (1191442204589) > > ... end of run > > > > c:\jakarta-jmeter-2.3RC4\bin>echo %errorlevel% > > 0 > > > > The failure shows up nicely in the HTML report that I can generate with > the XSLT stylesheet, but it would be extremely helpful if the command would > return a non-zero exit code if a test fails. This allows me to better > integrate JMeter in our test automation framework. > > > > Thanks in advance, > > Rico. > > > > > > -- > > Psssst! Schon vom neuen GMX MultiMessenger gehört? > > Der kanns mit allen: http://www.gmx.net/de/go/multimessenger > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] -- Psssst! Schon vom neuen GMX MultiMessenger gehört? Der kanns mit allen: http://www.gmx.net/de/go/multimessenger --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

