-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Query for all qm components on a GC #60
Comments
Running oslcquery on a QM project with three components all contributing to a GC, specifying a GC project and configuration, I get results for test cases from all three components. My commandline is oslcquery -A qm,gc -G "SGC Production Stream" -O testcases.csv -p "SGC Quality Management" -E "SGC GC" -s * Where:
This gets 36 results - one component has 30 test cases, the second has 3 and the third component also has 3. So AFAICT oslcquery does what you're looking for, at least with 7.0.2 SR1 iFix025 What version+ifix are you using, What's your commandline? |
Similarly querying for test plans by adding option |
Are you on the most recent version of elmclient? oslcquery shows the version when it runs, should be 0.26.2 I think. |
Here's a gotcha that might have got you - by default oslcquery caches responsed from the server for 7 days for everything except the query itself, which can cause problems when important things change - if you put option |
Hello, I confirmed I was using a bit old version from elm client, so upgraded it and followed your recommendation using However I can see this 2 issues:
(Also tried using
Actually, what more disturb me now is the second point about the uris, as this is also happening also quering component by component (despite for default one). |
Your (2) is straightforward - the URI needs to be used with the configuration URL added to specify the test case fully, otherwise if you don't provide a configuration the uri is searched for in the default configuration in the default component and not found because it's not in that config. Same for RM artifact uris. The default config is the 'initial stream' of the original component of the project. Be aware that the default configuration can be archived so don't rely on URIs without configuration always working. You could modify the code that saves the result to add a column with the full uri-in-configuration like: URI?oslc_config.context=CONFIGURI For (1) there was a defect in DN which had a similar effect of varying numbers of results but only when paging was in used, that's why by default paging is now disabled just like --pagesize 0. I don't have large ETM data to try reproduce this. If you're using |
hi, would you please provide an example to get Testcases just for specific component? If you wish, I can afterwards contribute to the project putting such examples to the README. Thanks in advance! |
For an ETM project "SGC Quality Management", in component "SGC MTM" for (local) configuration "SGC MTM Production stream" this will get all the testcases: oslcquery -A qm -p "SGC Quality Management" -C "SGC MTM" -F "SGC MTM Production stream" -O testcases.csv -s * |
somehow your suggestion above didnt work for me and I get the usual error: requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: https://abcd.com/qm/oslc_config/resources/com.ibm.team.vvc.Component |
Are you using the most recent elmclient version 0.26? Which version of Python, is it from python.org? What version+ifix of ELM are you using? I've found a defect in ETM 7.0.2, resolved in 7.0.3, which causes this sort of error when you aren't a member of the project - can you check if you're a member? If this is the problem then until you can upgrade to 7.0.3 the only really practicable workarounds are to be made a member of the project, or to get JazzAdmin privilege.
Why? If you query in a GC context oslcquery will give you results from that GC context's contributions, i.e. not just one contribution/component. |
we are using: we run the query with user which is a member of the project and has following roles: ETM: 7.0.2 SR1 -> is this then the issue? |
If you're a project member then that defect shouldn't be the problem. Sorry I don't have any idea what else might be going wrong. |
if you use the -V option for OSLC Query it will show the Full Query URL with local configuration (also without configuration) - use this in a REST client, you'll need to provide headers OSLC-Core-Version: 2.0 and Accept: application/rdf+xml. It's possible that ETM always pages the results, but you could try adding |
FYI In 0.26.3 there will be an explicit |
Hello!
We are trying to get all testcases from a qm project.
This project is configuration management enabled and has more than one components. All this components are contributing to a GC.
We are trying to query to this qm project with the GC project and GC stream, and the query works but only extracts the testcases from the default component.
Do you know if is there a way to extract test cases from all the components or any workaround to deal with this?
Thanks a lot in advance!
The text was updated successfully, but these errors were encountered: