4 Comments
ThomasCasserly wrote:
Hi Alex,
I have no idea, how would I find it? FYI I'm using keyword tests in case that makes a difference.
Hi ThomasCasserly - I was answering your question to Alex about finding the code line that causes the error, because you said you didn't know how to find it. Now you do!
Ah, ok, thanks Marsha. I thought "code line" was something to do with viewing the test as script, not that it was just the keyword test line 🙂
- If you click on the error message in the log, it will take you to the line in your test that causes the error.
Thanks Marsha,
Was already aware of this, but I appreciate the suggestion.👍
> I'm using keyword tests
Then a screenshot of the operation that causes the error along with operation's parameters.
Hi Alex, screenshot is attached.
Could it be the length of the PropertyName and PropertyValue?
Just noticing that they are quite long. I'm not aware of any character limit but just jumped out as a possibility,
Thanks
Hi,
Initial note: it is my guess that there is no exception, but just the 'Object not found' error. Am I correct?
> Could it be the length of the PropertyName and PropertyValue?
Not the length, but parameters themselves.
Basically, your code is like this:
a.b.c.WaitProperty(a.b.c, a.b.c.Exists, -1);
which in human language means: for object a.b.c get its property a.b.c and infinitely wait until this property will get value of a.b.c.Exists.
Notes:
a) In order for .WaitProperty to be callable, all its parent objects (a, b and c) must exist. If any of them does not exist one will get the 'Object not found' error in test log with the specification what object did not exist;
b) a.b.c resolves to object, but you are trying to use it as a string parameter that specifies the name of the property you are waiting for;
c) a.b.c.Exists resolves to either True or False, but you are trying to use it as a value parameter. So, depending of whether or not object c exists, your code will wait for the property to become equal to either True or False.
Technically, this piece of code might look like this:
a.b.c.WaitProperty('Exists', true, -1) // wait infinitely until for the object c the value of Exists property becomes equal to true
but note that this code will work only if object a and object b and object c, all of them do exist. Otherwise this code will fail with the 'Object not found' error.
Related Content
- 6 years ago
- 4 years ago
- 3 years ago