Merge ~caleb-ellis/maas:no-commission-test-suppress into maas:master

Proposed by Caleb Ellis
Status: Merged
Approved by: Caleb Ellis
Approved revision: 6824b45122e33655b96e06cd43f6901f1b583b10
Merge reported by: MAAS Lander
Merged at revision: not available
Proposed branch: ~caleb-ellis/maas:no-commission-test-suppress
Merge into: maas:master
Diff against target: 35 lines (+7/-3)
1 file modified
src/maasserver/static/partials/script-results-list.html (+7/-3)
Reviewer Review Type Date Requested Status
Steve Rydz (community) Approve
Review via email: mp+367241@code.launchpad.net

Commit message

LP: #1828492 - Remove ability to suppress failed commissioning scripts via UI

Description of the change

## Done
- Hide suppress column and checkboxes in commissioning tab in node details
- Remove suppress option from action menu

## QA
- Check that you can't suppress commissioning scripts via the UI
- Check that you can still suppress individual tests in the hardware tests tab

## Screenshot
https://user-images.githubusercontent.com/25733845/57514184-c2b33300-7307-11e9-81a5-9cac1c8469a1.png

To post a comment you must log in.
Revision history for this message
Steve Rydz (steverydz) wrote :

LGTM +1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/src/maasserver/static/partials/script-results-list.html b/src/maasserver/static/partials/script-results-list.html
2index e68534f..56fd2be 100644
3--- a/src/maasserver/static/partials/script-results-list.html
4+++ b/src/maasserver/static/partials/script-results-list.html
5@@ -23,7 +23,7 @@
6 <table class="p-table-expanding p-table--controllers-commissioning">
7 <thead>
8 <tr>
9- <th style="width: 80px">Suppress</th>
10+ <th data-ng-if="nodeResultsManager._area === 'testing'" style="width: 80px">Suppress</th>
11 <th class="col-3">Name</th>
12 <th class="col-2">Tags</th>
13 <th class="col-1">Runtime</th>
14@@ -40,7 +40,11 @@
15 'is-suppressed': result.suppressed
16 }"
17 >
18- <td style="width: 80px; overflow: visible" aria-label="Suppress"">
19+ <td
20+ data-ng-if="nodeResultsManager._area === 'testing'"
21+ style="width: 80px; overflow: visible"
22+ aria-label="Suppress"
23+ >
24 <div class="p-tooltip">
25 <input
26 id="{$ result.id $}"
27@@ -81,7 +85,7 @@
28 <button class="p-contextual-menu__link" aria-label="Hide metrics" data-ng-if="result.showing_results" data-ng-click="toggleMenu(); result.showing_history = false; result.showing_results = false">Hide metrics</button>
29 <button class="p-contextual-menu__link" aria-label="View previous {$ result.result_section $}" data-ng-if="!result.showing_history" data-ng-click="toggleMenu(); loadHistory(result)">View previous {$ result.result_section $}</button>
30 <button class="p-contextual-menu__link" aria-label="Hide previous {$ result.result_section $}" data-ng-if="result.showing_history" data-ng-click="toggleMenu(); result.showing_results = false; result.showing_history = false">Hide previous {$ result.result_section $}</button>
31- <button class="p-contextual-menu__link" aria-label="Toggle this test in machine list" data-ng-if="isSuperUser() && isSuppressible(result)" data-ng-click="toggleSuppressed(result)">{$ result.suppressed ? "Show" : "Suppress" $} test in machine list</button>
32+ <button class="p-contextual-menu__link" aria-label="Toggle this test in machine list" data-ng-if="isSuperUser() && isSuppressible(result) && nodeResultsManager._area === 'testing'" data-ng-click="toggleSuppressed(result)">{$ result.suppressed ? "Show" : "Suppress" $} test in machine list</button>
33 </div>
34 </div>
35 </div>

Subscribers

People subscribed via source and target branches