How to match specific content of a drop down in TOSCA without selecting it? - tosca

Is there a way to verify that if a drop down contains a specific option without selecting that option in TOSCA?

Yes there that is possible. I tried it with a standard HTML combobox. For that you need to scan the page. Select the combobox in question and change the quickfilter to show the items from the drop down. Check the combobox itself and one of the items below (does not matter which one):
You can ignore the message that the item is not unique - just create the module.
Once you have the module in place, you can rename the item, so that it reflects that you want to use it as a generic item. Then (in the properties tab) add a 'Configuration Parameter' and call it 'ExplicitName' and set it's value to true. This will allow to edit the name of the item in the testcase. (more details in the help of Tosca 11.1)
You can then create a testcase and use the module on it. In the testcase you can change the name of the item to the text of the drop down item you want to check for (you can also use wildcards) and then verify that it exists.

Related

How to select tab programmatically?

I need to switch from current tab to another without clicking on the tab itself.
In Clarity's documentation, you can see that the *clrIfActive directive accepts a boolean input to force a tab to activate.
So in your case, just pass true to the *clrIfActive of the tab you want to programmatically select. How you do that depends on how you create your tab in the first place: statically, with an *ngFor, based on a specific tab model, ... We can't help you out more unless you provide an example of what you are trying to do.

Changing the function of dynamic links in info parts

I am trying to let an info part's dynamic link work so that it only opens the queried values in a list on the new form.
Basically now, if i click Installation No. on the form part below.
Then this form opens up with all the Installations, not only the related Installations.
What i want to happen is when the Installation No is clicked then the list should look like when the "more" button is clicked or like the image below.
It seems like this is the standard function but i want to know if there is a way to change it.
Does anyone know a solution to this or know if there is any?
Dynamic links should work on info part forms provided prerequisites are met:
A data relationship exists between two tables, usually as one-to-many (one parent row relates to many child rows).
Each table has a field of the same extended data type.
In the parent table, the extended data type field values uniquely identify each row.
The extended data type has a relation defined on it for the field in the parent table.
Each table is a data source for one of the two forms.
The parent form contains a button that launches the child form.

Can we copy the value of one field to another in a repeating table of infopath form?

Hi guys can anyone tell me how to copy a field value in a repeating table to another field when we insert another row. It is just like amazon checkout process. In Amazon checkout process we have to click a check box when our billing address is same as our shipping address.
In this scenario am having one text box and drop down box fields in a repeating table. When am writing something in the text box and inserting another row. here come the problem I have inserted a value in the drop down box, when the value is selected in the drop down box the textbox value from the parent should be copied to the child node. This has to be done without any code behind.
Please help me regarding this issue
You could probably do this using the default value of the child node.
The default value can reference another field either on your main datasource or any secondary datasource.
I would assume that you don't want this updating when the user adds another child node. If that is the case then you will need to uncheck the "Update this value when the value of the foumlua is recalculated."

How do you make drag and drop always copy (never remove) in a Flex 4 Spark List?

Using the built in drag and drop features in Flex I can drag an item from one list and drop it into another list. But this removes the item from the first list. In my case I need to keep the items in the original list. So I need to always create a copy behavior for my users.
There is a property called, "dragMoveEnabled" that was set to "true".
From the documentation:
The description of this property is, "A flag that indicates whether items can be moved instead of just copied from the control as part of a drag-and-drop operation. If true, and the dragEnabled property is true, items can be moved. Often the data provider cannot or should not have items removed from it, so a MOVE operation should not be allowed during drag-and-drop."
When set to false or removed I'm getting the behavior that I want which is Copy always without having to also press the CTRL key for it to work.

Is it possible to catch a comboBoxes value before change with a change event

I am displaying a combo box in something of a WYSIWYG preview. I want the user to be able to click on the combo box and see the options inside, but I don't want them to be able to change the value. I tried using preventDefault() on the change event but it doesn't work. I don't want to disable it because I do want the user to be able to "look inside" the dropdown.
So I'm trying to block the change, but can't. My next resort is to change the selected index back to what it was before the change, Is there any way to do this within the scope of a ListEvent.CHANGE event listener?
Current Workaround is to basically re-assign the controls selected item the same way I am defining the selected item when I originally build it (a default selection). So a user sees their change then it immediately changes back to the default selection.
Are you sure that a combobox is what you want? could you do the same thing with a list component that is not selectable?
update:
If you must use a combobox and you dont want the lag from listening for the event and resetting the control, I see two possible options. You could subclass the control and make your own. When you do, hijack any methods that set the value besides the initial selection.
Or, you could try something like this: http://wmcai.blog.163.com/blog/static/4802420088945053961/. The site seems like it is in another language but the code is still there. It will allow you to make your options disabled, so the user cannot choose one of the other options.
HTH

Resources