HP ALM OTA get Requirement for Test - alm

I need the Requirement ID for a Test.
The only code sample I found does this for a Bug:
http://alm-help.saas.hp.com/en/12.50/api_refs/ota/topic157.html
Cheers,
Stefan

There is a Method GetCoverList() in the Test object which gives you a list of Req objects which have a property ID.

Related

REST API - Attach a file to an AP Credit Adjustment via key fields

I am trying to attach a file to a Credit Adjustment via REST API by indicating the key fields.
For a regular Bill, this PUT request is successful:
https://{URL}/entity/Default/18.200.001/Bill/Bill/003838/files/Attachment Test 2.pdf
However, I am having issues identifying how should the Key1 be changed for Credit Adjustments.
I have tried a series of combinations w/o success.
Thanks.
I know Chris already answered but I wanted to share that you can find these values for any other drop down key field by opening a record of the doc type you want and looking at the URL
Try this
http://localhost/YourERP/entity/Default/20.200.001/Bill/ACR/[RefNbrHere]/files/EL Paso Texas.txt
Be sure that your file is included in the payload

Get the Duration an Outlook Email was Composed for

I've looked at the Message (email) class in the Office 365 API Resource Reference, as well as the other classes and various Office 365 docs, but there doesn't seem to be an elegant method for obtaining the duration a user spent composing an email. I'm very surprised that the Message class does not have a "ComposedTime" attribute or something along those lines, for emails in the SentItems (Sent) folder.
My current implementation is very brute-force, I am hoping there is a more straightforward implementation, thank you!
The back end doesn't track that, so no, there is no property for it. You can always suggest it on UserVoice.

hybris FlexibleSearchService can't find a product that actually exists

I'm trying to add a product to my cart, like this:
cartFacade.addToCart("M300044", 2);
And it fails with: Product with code 'M300044' not found!
When I debug the code, I find that this query is executed by FlexibleSearchService.search(query):
SELECT {c:pk} FROM {Product AS c} WHERE {c:code}='M300044'
If I execute this query on my hybris Admin console, I do get a Product as a result.
Why can't FlexibleSearchService find it though? Is it something to do with setting a catalog version somewhere?
In this case it was because I was doing this from a Test class, so hybris couldnĀ“t find the product because there was no data whatsoever in the junit tenant.
So I had to create the data in the setup method of my Test class, which is executed before the actual test method is called.
You need to make sure one more thing that you have set the session user = admin , because if there is a restriction applied on u r product then your test case won't work
I believe this is a SYNCHRONIZATION issue.
STAGED Product Version is not aligned with Online.
You have two options.
HMC > System > Facet Search > indexer wizard.
Product Cockpit.
Check available stock for product in hmc. May this help you
initialize Junit tenant so by checking import sample data yes so that data which you have in production will be available for testing.
you need to make full SOLR indexing for the products from hmc before they can appear in front end store or using hypris APIs
hope that help

"Document has been modified or corrupted since signed! (data)" Message

I'm running an agent which modifies view column title (using NotesViewColumn class). Everything is fine until I open the modified view, in the status bar below it says "document has been modified or corrupted since signed! (data)". Any suggestion on how to solve this. Thanks in advance.
I get the view as a NotesDocument object using NotesDatabase.getDocumentByUNID('unid of view') and used sign() and save() methods, it worked :) thanks again

Adding custom properties in CodedUI Test builder

I want to add custom properties of my control to CodedUI test builder. How can i achieve it?
I have used Automation provider to implement support for codedUI test in the control().Only the properties returned by the AutomationElementIdentifiers are visible in the assert window now, what should i do to include the other custom properties in it?
Please guide me to resolve this.
Thanks
The following is an example of adding custom properties to a link, but it applies to any other control.
HtmlHyperlink myLink;
myLink.SearchProperties.Add("InnerText", "Custom Inner Text", PropertyExpressionOperator.EqualTo);
I have never actually used the following and not sure if it even applies to coded-ui, but I know it exist.
myLink.SetProperty("PropertyName", "Something");
Thank you for your suggestion, unfortunately it doesn't works.
Finally i realize what is happening in my case, While using Automation Provider in a custom Control(like Grid) we can select the cells and can return only the properties supported by the AutomationElementIdentifiers, it is not possible to return the custom properties of the control to the test builder.
In case of control type i can return only the controltypes comes under the AutomationIdentifier.
So for my grid cell i used ControlType.Edit, but its not much helpful, the values in the Grid cells are not returned. So i decided implement the CodedUI support for my control as described in MSDN .
Thanks
Kalai

Resources