18 January 2026:


This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.



Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.

JUnit logs problem

MarSilMarSil Members
edited November -1 in Sahi - Open Source
Hi,

I am using ant to execution tests and I have following problem with JUnit logs. When I start the test it normally works and finish but the JUnit log is poor. It contains only few lines:

<?xml version="1.0" encoding="UTF-8" ?>
<testsuite errors="0" failures="0" name="run.sah.run" tests="1" time="61.961">
<testcase classname="run.sah.run" name="run.sah" time="61.961">


The html log is created correctly with all steps of test.


ant file:
...
<target name="run-suite-on-browser">
<sahi suite="${suite.path}"
browser="${browser-path-to-executable}"
browseroption="${browser-options}"
baseurl="${url}"
sahihost="localhost"
sahiport="9999"
failureproperty="sahi.failed"
haltonfailure="false"
browserProcessName="${browser-process-name}"
threads="1">
<report type="junit" logdir="${user.data}/logs"/>
<report type="html" logdir="${user.data}/logs"/>
</sahi>
<antcall target="sahi-check-for-failures"/>
</target>
...



Do you know anyone where is problem?



Thanks
Martin

Comments

  • Ok I got it. The problem causes sahi(v.3.5) because old version(3.0) works fine(xml file is generated correctly).

    Could it be repaired in the next versions?


    Best regards
    Martin
  • Hi Marsil,

    This was an intentional change.
    In Sahi V3.0 and older, each step in a sahi script was considered as a testcase which was incorrect. Ideally, it should be the sahi script itself.
    This was also implemented for integration with Jenkins/Hudson.

    If you really need an XML file with all the steps, you can try Sahi Pro. Sahi Pro lets you create concise XML, SQL, DB and HTML based reports.

    Regards,
    dkulkarni
  • Nice post. I like the way you start and then conclude your thoughts
Sign In or Register to comment.