Writing log messages of test to the file
Hi, When TestComplete is being used, We try to write log messages which are come out of the "Log. Message()" or "Log.Error()" function to a text file in order to keep the log messages together as a log.txt. However, after creating a file, we try to use "Log.File()" function or "SaveResultsAs()" to write logs messages to this file, It just created the file, could not write anything. Is there any way to keep log messages that are written in the test script in the txt file in a given directory? as an example code; function creatingAndWritingLogMessagesToTheTxtFile(){ //create a file var filePath="C:\\.....";//Directory aqFile.Create(filePath); var logName="filePath"+".mth"; Log.SaveResultsAs(logName,lsMHT); } And in the functions how we can write the log messages to this created file that is created to keep log messages? as an example code; function testA(){ //....codes doing something Log. Messages("Test Successful"); //Here How can we use that method (If it is useful) to write this log to that text file?? }Solved1.3KViews0likes3CommentsOption to switch logging tabs from bottom to the right
It would be great if there were an option to change logging tabs from the bottom to the right side of the gui. Sometimes I'm monitoring properties and steps in a test, and I'd like to see the script log specifically on the right. This way we have more control over the screen real estate. Currently if you want to view both, you have to sacrifice space for script logs, or observing teststeps, or properties.602Views0likes0CommentsError while loading a test case in readyapi-3.2.5
Hi, Recently i created a test case that involves few database calls, and i did some calculations, now whenever I am launching readyapi (Version - 3.2.5), I am always getting error in the readyapi logs as An error occurred [error: Premature end of file.], see error log for details An error occurred [java.lang.NumberFormatException], see error log for details And when i look in the Error logs, I found this info https://pastebin.com/J2B1f2vU I am not able to find which step is causing this error, reason when i run the test case I do not see it failed at any step. Please advice.Solved2.8KViews0likes6CommentsHow To Export Multiple Existing Test Logs as MHT
Hi there! I am trying to implement what I feel should be an easy solution. (I will just pre-empt this by saying I know you can add an event to call Log.SaveResultsAs() to generate an MHT file of the currently running test OnStop etc, but I cannot modify events as it will greatly impact our test running time for CI if MHT files are generated after each test case (our cases are quite long). Of course its a trade-off we can make, but I wanted to see if I could do something else instead!) Here as an example I have multiple logs for test runs that havealready occurred. (I cant find an equivalent Log/slPack method to export pre-existing Logs to MHT, only currently running tests.) If I right click onone of these, I have the option to Export Logs. However, it seems that I cannot bulk export them - I only have an option to Remove if I select more than one. It is not that I want to export all of these different logs into one MHT file (that wouldn't make sense!), I just wish to be able to select multiple files, and have them all exported to their own MHT files at some desired location. I have tried to do this programmatically as I mentioned, but I cannot find a means of exporting already existing logs. Any advice for this seemingly simple task would be greatly appreciated! Kind Regards, PJSolved1.5KViews0likes2CommentsTestcomplete 14 SaveResultsAs does not export summary.htm
Hi, I use Log.SaveResultsAs(FileName,LogFormat,ExportVisualizerImages,LogScope) for export Testresults in HTML after the testrun, call is : Log.SaveResultsAs(logpath, lsHTML, true, 0), logpath is defined in a variable. Testcomplete 14 has the summary report (summary.htm), when I call the export from Testcomplete ID or with commanline parameter, the file summary.htm will be exported, but when I use Log.SaveResultsAs the file summary.htm will be not exported. Is there something wrong with my call for Log. SaveResultsAs or does Log.SaveResultsAs not support the export of summary.htm? greentings Martin StrombergerSolved2.6KViews0likes4CommentsIs there a way to add script logs in reports ?
Hi, I would find very interesting to have my script logs in a report, how can I do that ? Otherwise, is there a way to have Test Results message more significant? It would be nice to know the data the test is running instead of Row 1, Row 2, Row 3, ....573Views0likes0CommentsAllow setting ReadyAPI working directory for user
Feature request:Please consider adding aglobal log file location and removing the dependency on the bin/ directorybeing writeable by the user running ReadyAPI (or testrunner.sh, etc). Evenbetter would be if you would support using a variable in the path, orsimply relative paths, so that the ReadyAPI logs of one project could beplaced under the project's working directory. I'm not overly familiar with ReadyAPI but I imagine the ideal location inwhich to specify a log path would be in soapui-settings.xml. Background (as per our forum post and support ticket): We have installed in a system-wide location at /opt/SmartBear/ReadyAP-1.2.2, but unless we make the bin/ subdirectory of that path writeable by the user (not a good idea!) the software refuses to start. Even giving write permissions to all of the individual log files that ReadyAPI expects to write to is insufficient. It requires write access to the bin/ subdirectory. If I temporarily make bin/ writeable, I can launch the GUI, run tests, etc. Even if installed into a user's home directory, we'd prefer for logs not to be created in the same dir as the binaries. I have so far tried setting global properties as follows using the GUI: Name: soapui.logroot /home/user/soapui-workdir user.dir /home/user/soapui-workdir Neither of these worked when running our test suite, even after restarting the ReadyAPI GUI. I have tried various combinations but ended up having to make our user theowner of the directory for ReadyAPI to even launch at all. I had consideredediting soapui-log4j.xml but thought it was bad form to do so (and it'slikely changes will be over-written next time we upgrade ReadyAPI). I think many *nix systems administrators would be concerned about the factthat ReadyAPI requires write access to the binaries directory (not just thelog files in it, but the whole directory).4.6KViews0likes2Comments