Merge ~alextu/plainbox-provider-pc-sanity:turbostat-long-idle into plainbox-provider-pc-sanity:master

Proposed by Alex Tu
Status: Merged
Merged at revision: 0f801169357366f24f41d18942c832c82cdb0d5a
Proposed branch: ~alextu/plainbox-provider-pc-sanity:turbostat-long-idle
Merge into: plainbox-provider-pc-sanity:master
Diff against target: 70 lines (+38/-2)
3 files modified
debian/changelog (+6/-0)
usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-power-consumption.pxu (+31/-2)
usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-smoke-test.pxu (+1/-0)
Reviewer Review Type Date Requested Status
Cyrus Lien Approve
Leon Liao Pending
OEM Solutions Group: Engineers Pending
Review via email: mp+382728@code.launchpad.net

Description of the change

    to check turbostat in longidle

    detail history: https://trello.com/c/3C0b5Nkt

To post a comment you must log in.
Revision history for this message
Cyrus Lien (cyruslien) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/debian/changelog b/debian/changelog
2index 91a3d8c..984d7d6 100644
3--- a/debian/changelog
4+++ b/debian/changelog
5@@ -1,3 +1,9 @@
6+plainbox-provider-pc-sanity (0.2.6ubuntu2) UNRELEASED; urgency=medium
7+
8+ * to confirm the CPU package state in long idle
9+
10+ -- Alex Tu <alex.tu@canonical.com> Wed, 22 Apr 2020 14:25:12 +0800
11+
12 plainbox-provider-pc-sanity (0.2.6ubuntu1) bionic; urgency=medium
13
14 * bump version
15diff --git a/usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-power-consumption.pxu b/usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-power-consumption.pxu
16index 3002587..d7726a9 100644
17--- a/usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-power-consumption.pxu
18+++ b/usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-power-consumption.pxu
19@@ -16,8 +16,37 @@ command:
20 fi
21 fi;
22 done;
23- sudo turbostat --num_iterations 20 --show "$COL" 2>&1 | tee "$report_folder"/turbostat-pkgpc.log
24+ sudo turbostat --num_iterations 20 --show "$COL" 2>&1 | tee "$report_folder"/turbostat-pkgpc-shortidle.log
25 tail -n1 "$report_folder"/turbostat-pkgpc.log | grep "0.00$" && false
26 _summary: check if target machine can get cpu pkg c10 in short idle.
27 _description:
28- check if target machine can get cpu pkg c10 in short idle.
29+ check if target machine can get cpu pkg c10 in short idle. detail history: https://trello.com/c/3C0b5Nkt
30+
31+plugin: shell
32+category_id: com.canonical.plainbox::miscellanea
33+id: miscellanea/turbostate-long-idle-c10
34+command:
35+ set -x
36+ report_folder="$HOME/submission-report-$(date +%Y%m%d%H%M)"
37+ mkdir -p "$report_folder"
38+ dpkg -s linux-tools-"$(uname -r)" || sudo apt-get install -y linux-tools-"$(uname -r)"
39+ dpkg -s xautomation || sudo apt-get install -y xautomation
40+ gsettings set org.gnome.desktop.session idle-delay 10
41+ sleep 10
42+ for i in $(sudo turbostat --list | sed 's/,/ /g'); do
43+ if [ -z "${i##*pc*}" ]; then
44+ echo $i
45+ if [ -z "$COL" ]; then
46+ COL="$i";
47+ else
48+ COL="$COL,$i";
49+ fi
50+ fi;
51+ done;
52+ sudo turbostat --num_iterations 20 --show "$COL" 2>&1 | tee "$report_folder"/turbostat-pkgpc-longidle.log
53+ tail -n1 "$report_folder"/turbostat-pkgpc-longidle.log | grep "0.00$" && false
54+ DISPLAY=:0 xte 'key Up'
55+ gsettings set org.gnome.desktop.session idle-delay 0
56+_summary: check if target machine can get cpu pkg c10 in long idle.
57+_description:
58+ check if target machine can get cpu pkg c10 in long idle. detail history: https://trello.com/c/3C0b5Nkt
59diff --git a/usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-smoke-test.pxu b/usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-smoke-test.pxu
60index 42d14e7..f767966 100644
61--- a/usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-smoke-test.pxu
62+++ b/usr/share/plainbox-provider-checkbox/units/pc-sanity/pc-sanity-smoke-test.pxu
63@@ -5,6 +5,7 @@ _description:
64 This test plan is for smoke test as sanity before release image.
65 include:
66 com.canonical.certification::miscellanea/turbostate-short-idle-c10
67+ com.canonical.certification::miscellanea/turbostate-long-idle-c10
68 com.canonical.certification::miscellanea/thermal
69 com.canonical.certification::miscellanea/dump_libsmbios_tokens
70 com.canonical.certification::miscellanea/dump_libsmbios_tokens_attachment

Subscribers

People subscribed via source and target branches