I’m trying to record a test case which involves selecting a database object under a node.
When I double click on the data base object type node, for example Tables, I need a wait for the tables node to be populated. I use this:
ui.wait( new TreeItemLocator(TreePath + "/" + objType + ".*" + "/" + objName,ftl ).isVisible() );
-> TreePath/Tables (120)/TableName
I seems that there is a problem in the above line with ".*" which indicates the number of objects for that node. If I use instead the number of objects, the wait works fine.
This is the error that I get:
com.windowtester.runtime.WaitTimedOutException: Timed out waiting for condition:
I need to use ".*" because the number of objects changes very often on the database and I don’t want to modify the test every time I run the test.
I have the same problem with the assert:
ui.assertThat( new TreeItemLocator(TreePath + "/" + objType + ".*" + "/" + objName,ftl ).isVisible() );
Can you tell me please if there is some other way to make the test work?