Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.
 

UI Script to set default sorting of Test Runs


#1

Is it possible to change the default sort value for test runs to be by Status_ID? To give you a scale of what I want to reference it could pertain to either the individual grouping of test cases within a run to their status ID or the entire document of test runs to status ID.

I’ve tried two UI Scripts, one running App.Tables.group_by = ‘cases:status_id’; and the other running App.Runs.setTestGrouping(‘tests:status_id’);.

Currently neither of my scripts work. I’m not sure if that means I’m referencing these calls incorrectly(I’m not extremely familiar with javascript, learning as I go) , or if these are default values set by test rails that override my UI Scripts.

Any help would be appreciated.


#2

Hello,

Thanks for your posting. Changing the grouping for tests via UI scripts/JavaScript is currently not supported. You can simply click on the Status header in the tests table for this. The grouping will be remembered for your user and also used the next time you load this page. Adding an option for setting the default grouping for all users is already planned and we would like to look into this for one of the versions after the next one.

I hope this helps and please let me know in case you have any further questions.

Regards,
Tobias


#3

Thanks for the info. I figured that was the case. The last used config is good for now, but I’d love to see a setting to change the default for all users.

Much appreciated.


#4

We are definitely looking into it for a future version. Thanks again for the feedback!

Regards,
Tobias


#5

Is Default sorting is now supported with latest version 5, I want to make Section as Default sorting my project.

Please help me,

Thanks,
Nathan S


#6

Hello Nathan,

The default ordering/sorting is already set to the Section attribute and you can change this via the Sort: option on the test run / suite pages.

I hope this helps!

Cheers,
Tobias