Merge lp:~brendan-donegan/checkbox/bug1177647 into lp:checkbox

Proposed by Brendan Donegan
Status: Merged
Approved by: Zygmunt Krynicki
Approved revision: 2174
Merged at revision: 2178
Proposed branch: lp:~brendan-donegan/checkbox/bug1177647
Merge into: lp:checkbox
Diff against target: 25 lines (+3/-1)
2 files modified
checkbox-old/checkbox_qt/qt_interface.py (+1/-1)
checkbox-old/debian/changelog (+2/-0)
To merge this branch: bzr merge lp:~brendan-donegan/checkbox/bug1177647
Reviewer Review Type Date Requested Status
Zygmunt Krynicki (community) Approve
Review via email: mp+168915@code.launchpad.net

Description of the change

For some reason the show_tree function in qt_interface.py did not sort the dictionary of items to be displayed in the test selection tree, so the order would be random as expected from a Python dictionary.

Simply sorting the list of items causes the tests to be shown in order at the test selection view. Note that this will always be alphabetical order, and has nothing to do with the order of the tests in the whitelist.

To post a comment you must log in.
Revision history for this message
Zygmunt Krynicki (zyga) wrote :

Looks good. I'll give it some testing and land it. Thanks

Revision history for this message
Zygmunt Krynicki (zyga) wrote :

+1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'checkbox-old/checkbox_qt/qt_interface.py'
--- checkbox-old/checkbox_qt/qt_interface.py 2013-06-03 15:00:37 +0000
+++ checkbox-old/checkbox_qt/qt_interface.py 2013-06-12 10:54:29 +0000
@@ -147,7 +147,7 @@
147147
148 def buildBranch(options, default, baseIndex="1"):148 def buildBranch(options, default, baseIndex="1"):
149 internalIndex = 1149 internalIndex = 1
150 for test, state in options.items():150 for test, state in sorted(options.items()):
151 active = test in default151 active = test in default
152 if isinstance(state, dict):152 if isinstance(state, dict):
153 indexedOptions[153 indexedOptions[
154154
=== modified file 'checkbox-old/debian/changelog'
--- checkbox-old/debian/changelog 2013-06-11 16:26:40 +0000
+++ checkbox-old/debian/changelog 2013-06-12 10:54:29 +0000
@@ -23,6 +23,8 @@
23 * jobs/touchpad.txt.in - Remove the requires line for touch_mode in23 * jobs/touchpad.txt.in - Remove the requires line for touch_mode in
24 touchpad/horizontal and touchpad/vertical so that those tests will24 touchpad/horizontal and touchpad/vertical so that those tests will
25 at least run on those systems where they are supposed to (LP: #1184882)25 at least run on those systems where they are supposed to (LP: #1184882)
26 * checkbox_qt/qt_interface.py - Order the list of items to be displayed
27 alphabetically, so the order is consistent (LP: #1177647)
2628
27 [ Daniel Manrique ]29 [ Daniel Manrique ]
28 * jobs/stress.txt.in: fixed a few inconsistent invocations of sleep_test.30 * jobs/stress.txt.in: fixed a few inconsistent invocations of sleep_test.

Subscribers

People subscribed via source and target branches