Ask a Question

Stop actions from being added to log

Occasional Contributor

Stop actions from being added to log

Hello Everyone, 


I'm creating a script to remove entered text from 6 separate fields and because of the nature of the test, I have to do this at least 5 times.


The script works as intended, but on the final log you see the following:




My question is, is there a way to omit those from being added into the log? It really does make it convoluted after several runs and takes away from the pertinent information the log is going to give. Ideally, I would still have a log entry that would say, "All field values have been reset to null"


Here is the code I'm using:


def ClearAccountRegistrationFields():


Esteemed Contributor

Yup.... go to Tools | Current Project Properties | Playback... there's an option there that says, "Store last ___ events". 


Right now it probably says 0.  Set that to some value like 10 or 20.  What this will do is will suppress all those "Event" messages except for the configured last few before any Warning or Error that is logged.  This way, you won't see all those unnecessary events but, when an Error or Warning is logged, you'll get events to show the last few steps that lead up to the error.

Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
Showing results for 
Search instead for 
Did you mean: