For our Robot framework Automation i want to:
from our project (e.g. PRJ)
extract gherkin test steps from the testing board.
The test-case is created with cucumber steps and dataset. (PRJ-001)
The test-case is executed in a execution (PRJ-002)
I'm trying to do this with API and/or GraphQL, but no success as so far...
My question is it possible?
The reason is that we want to have 1 source of information (which is XRAY) for creating test-cases.
I can access the Test-cases and i can access the Test-Executions and get the information
the problem is that when using a dataset linked to cucumber in the testingboard there will be more test-cases/ examples/ iterations which i cannot retrieve.
Finally got it. Pulling :
Project ID with :
query GetProjectId($projectKey: String!) {
getProjectSettings(projectIdOrKey: $projectKey) {
projectId
}
}
With this project ID, i can pull the test keys from the repository:
query GetTests($projectId: String!, $path: String!) {
getTests(
projectId: $projectId,
folder: { path: $path, includeDescendants: false },
limit: 50
) {
results {
issueId
testType {
name
}
jira(fields: ["key"]) # This is the correct way to request Jira fields
}
}
}
Next is getting the individual test-details with :
query GetTestDetails($testKey: String!) {
getTests(jql: $testKey, limit: 1) {
results {
jira(fields: ["key", "summary"])
gherkin
testType {
name
}
steps {
id
data
action
result
}
dataset {
parameters {
name
type
}
rows {
order
Values
}
}
}
}
}
Mixing it all together with a little python script and now i'm able to convert the Test-cases (only Cucumber and Manual by the way, as generic is not supported from the cloud with API/GraphQL)
So i've managed to answer my question.
Welcome to the community.
Best advice I can give is to contact Xray support on your requirement and see if this is possible.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sample Test-case:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Above are extra screenshot on what i want in my scripting to retrieve and how it gets there...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.