How do we integrate the test evidences with X-Ray Jira via API's? - selenium

I want to upload the test evidences of an automation tests to the X-Ray Jira through API.
I need what API and Endpoint is being consumed to upload the test execution evidences to X-Ray Jira.

You can find information on the documentation regarding the API of Xray here: https://docs.getxray.app/display/XRAYCLOUD/Version+2
You also have multiple tutorials showcasing importing results from different tools and frameworks here: https://docs.getxray.app/display/XRAYCLOUD/TTT%3A+Automation
Make sure you use the right documentation version depending on your Jira installation: Cloud or Server/DC. The above documentation is for Cloud (you can find the same one for Server).

Related

BAPI_ACC_DOCUMENT_POST on ABAP Cloud?

On an on-premise we have option to call BAPI for CRUD operations. How can we achieve the same in SAP cloud environment. For example I am trying to find solution to post FI documents from external API into SAP Cloud, equivalent to bapi_acc_document_post in on-premise.
Thanks.
In Cloud Environment you can enable SAP API Business Hub to access APIs described in api.sap.com
There are several APIs available for different SAP Applications; for example check Journal Entry - Post (Asynchronous)
You can find a Business documentation describing the use cases from a functional perspective as well as technical informations (API Specs, WSDL, urls etc..)

Anypoint Platform Apps/Schedulers

Is there a way to get details of all the apps in an Anypoint Platform Business Group. For example, if there are 3 apps available in the RunTime Manager, I am looking at details like below:
I know there are cloudhub APIs which can get the details, but is there a custom API? If yes, can it be integrated with a reporting tool like PowerBI to create a live dashboard?
Please advise.
All or nearly all REST APIs provided by Anypoint Platform return JSON, including the CloudHub REST API. You can check the platform APIs in MuleSoft Dev Portal.
You can use the cloudhub/api/v2/applications/{domain} endpoint to get details of an application: https://anypoint.mulesoft.com/exchange/portals/anypoint-platform/f1e97bc6-315a-4490-82a7-23abe036327a.anypoint-platform/cloudhub-api/minor/1.0/console/method/%231839/
To get the schedulers information the endpoint there is a cloudhub/api/applications/{domain}/schedules endpoint: https://anypoint.mulesoft.com/exchange/portals/anypoint-platform/f1e97bc6-315a-4490-82a7-23abe036327a.anypoint-platform/cloudhub-api/minor/1.0/console/method/%233128/
Both return JSON responses with the information described in above links.
I don't know if that is useful for PowerBI. If not, you can develop your own custom application to query above information and return it in a suitable format. Your application can implement an API of your design if needed.

What are feature not supported by Apache Metamodel Salesforce conenctor

I had gone through the API provided by Apache metamodel to connect Salesforce.com, most of API are there which can help perform CURD operation. But, i am unable to find the features which are not supported by Apache metamodel API's.
Is there any document reference for complete API guide and feature document for Apache metamodel Salesforce.com connector ?
Only direct documentation I can find is on MetaModel's Wiki.
To answer this question from a Salesforce side: the most obvious caveat is that Salesforce isn't an ACID or SQL compliant database. The source for the Salesforce connector is the best place to see how everything is translated. The data context is a wrapper around Salesforce's Partner API, so you run the risk of no SQL to API translation being available.

API for Google Cloud Platform: gcloud API or Google API Client

I am working with google cloud platform. Learning and trying out a few things like Bigquery and Google Cloud Storage.
I find it confusing that there are two official APIs for all those things: gcloud API and Google API Python Client. In google cloud's "getting started" tutorial, the recommended API is Google API (Python) Client and it seems that the documentation for gcloud api is not very detailed.
In short, to access Google Cloud Platform programmatically,
which api library is better?
Where can I find nice documentation for that?
My answer
I would recommend gcloud API, this choice also applies to other languages: nodejs, ruby.... And then
Explanations
It is confusing, that Google have these two APIs have overlapping functionalities. And it is more confusing that they use Google API Client in their tutorial, while gcloud seems to be a more Google Cloud SDK specific package.
Here is what I found out: on the page of the gcloud API page, there is this FAQ section saying:
The Google APIs Python Client is a client library for using the broad set of Google APIs. gcloud-python is built specifically for the Google Cloud Platform and is the recommended way to integrate Google Cloud APIs into your Python applications. If your application requires both Google Cloud Platform and other Google APIs, the 2 libraries may be used by your application.
Addtionally, the gcloud api is part of the Google Cloud SDK. So it is standard.
Both the gcloud command-line tool and gcloud-python package are a part of the Google Cloud SDK: a collection of tools and libraries that enable you to easily create and manage resources on the Google Cloud Platform. The gcloud command-line tool can be used to manage both your development workflow and your Google Cloud Platform resources while the gcloud-python package is the Google Cloud Client Library for Python.
Based on my experience of using the python and nodejs api, the gcloud api is much more easier to use than the google api client. Here is another question for your reference:
When accessing Bigquery using Python API, what is the difference of using google client API and gcloud
So obviously, for a project working around Google Cloud Platform, using the gcloud API is an better choice.
Documentation
What about the documentation?
The documentation seems not very helpful(especially for rookie programmer like me) if you look at a page like this:
https://googlecloudplatform.github.io/gcloud-python/#/docs/master/gcloud/storage/blob/blob
I found two ways to get more detailed instructions: look for the doc for stable version or go to the github page. For instance:
https://googlecloudplatform.github.io/gcloud-python/stable/storage-blobs.html
https://github.com/GoogleCloudPlatform/gcloud-python
This is the result of the little research I did on it. I am still curious why Google mention gcloud library so little in its tutorials. Anyway, I hope this will help people to get an idea of which library to use, and save some time researching on it.

RESTful API Testbed with Swagger

I'm trying to develop an automated testing suite for a REST API. I've been told that Swagger would be the right tool to use to do this.
The API is being developed using the Spring Framework.
I can't figure out how I would use Swagger to do this.
From my understanding Swagger is used to create nice API documentation.
I've looked at this Dreamfactory blog post and it looks like they've got some kind of in browser testing functionality, but I don't think its really a test suite.
I've also taken a look at ServiceStack( and cucumber) but since its another framework I don't think it would work.
This google group discussion didn't see to point anywhere in particular either.
So, does anyone know how to develop a RESTful API testbed using Swagger?
Thanks!
As the other answers have mentioned, Swagger provides a way to define and document your API endpoints, methods, responses, errors, and more. It does not do any sort of automated testing out of the box.
There are a few tools that can read a Swagger definition to created automated tests, though:
Assertible is a tool where you can import your Swagger spec to automatically create tests and assertions for every endpoint and method. You can then set up monitoring, post deployment testing, and alerts. (Read the blog Testing an API using Swagger). It has a free plan with options to upgrade for more tests.
swagger-test is an NPM package, if you're looking for something to integrate with your code. I haven't personally used it, but it does look active and useful.
Dredd is another really cool open-source tool that will automate testing your Swagger spec against a live backend. This is also a CLI too, and it works with API Blueprint in addition to Swagger.
There's others as well, because Swagger provides a good common language for API developers there's some great tools that are written on top of it.
Another answer mentioned to check out the Commercial Tools page on swagger.io, which has some more hosted services (free and paid).
Full disclosure - I'm one of the co-founders of Assertible and would love to hear your feedback if you get a chance to use it.
Swagger will let you nicely document your API, and will help you do manual, live tests with swagger-ui in that you can easily fill in arguments and see the responses through a web ui. Try the Swagger demo as an example of what I am referring to. http://petstore.swagger.io/
I have not tried this, but this might be of interest for more automated testing against Swagger definitions.
https://github.com/Maks3w/SwaggerAssertions
You can find a lot of software using Swagger specification for (automated) testing of your REST API on http://swagger.io/commercial-tools/. But they are not free.
Postman is great tool to test with Swagger apis. It can also store requests and responses. More details as follows
https://www.getpostman.com/docs/importing_swagger.
You might also want to look at the community tools according to languages at this page. http://swagger.io/open-source-integrations/
I have written an article on how you can generate all the test logic by using the Swagger or OpenAPI specifications. And then feed test data through excel sheets. That way your test data and test logic remain separated and in future if your Swagger spec changes then you will be able to even quickly re-sync the test logic.