summaryrefslogtreecommitdiff
path: root/testcases
diff options
context:
space:
mode:
Diffstat (limited to 'testcases')
-rw-r--r--testcases/014-battery-capacity/expected_output.txt1
-rw-r--r--testcases/014-battery-capacity/i3status.conf13
-rw-r--r--testcases/014-battery-capacity/uevent7
-rw-r--r--testcases/015-battery-capacity/expected_output.txt1
-rw-r--r--testcases/015-battery-capacity/i3status.conf13
-rw-r--r--testcases/015-battery-capacity/uevent10
6 files changed, 45 insertions, 0 deletions
diff --git a/testcases/014-battery-capacity/expected_output.txt b/testcases/014-battery-capacity/expected_output.txt
new file mode 100644
index 0000000..3f97d1b
--- /dev/null
+++ b/testcases/014-battery-capacity/expected_output.txt
@@ -0,0 +1 @@
+Touchpad: 100.00% BAT \ No newline at end of file
diff --git a/testcases/014-battery-capacity/i3status.conf b/testcases/014-battery-capacity/i3status.conf
new file mode 100644
index 0000000..d48aa50
--- /dev/null
+++ b/testcases/014-battery-capacity/i3status.conf
@@ -0,0 +1,13 @@
+general {
+ output_format = "none"
+}
+
+order += "battery 1"
+
+battery 1 {
+ format = "Touchpad: %percentage %status %remaining"
+ format_down = "No touchpad"
+ path = "/sys/class/power_supply/hid-ff:ff:ff:ff:ff:ff-battery/uevent"
+ path = "testcases/014-battery-capacity/uevent"
+ low_threshold = 10
+}
diff --git a/testcases/014-battery-capacity/uevent b/testcases/014-battery-capacity/uevent
new file mode 100644
index 0000000..5f06cc9
--- /dev/null
+++ b/testcases/014-battery-capacity/uevent
@@ -0,0 +1,7 @@
+POWER_SUPPLY_NAME=hid-70:cd:60:f7:a0:5c-battery
+POWER_SUPPLY_PRESENT=1
+POWER_SUPPLY_ONLINE=1
+POWER_SUPPLY_CAPACITY=100
+POWER_SUPPLY_MODEL_NAME=applemagictrackpad
+POWER_SUPPLY_STATUS=Discharging
+POWER_SUPPLY_SCOPE=Device
diff --git a/testcases/015-battery-capacity/expected_output.txt b/testcases/015-battery-capacity/expected_output.txt
new file mode 100644
index 0000000..663a593
--- /dev/null
+++ b/testcases/015-battery-capacity/expected_output.txt
@@ -0,0 +1 @@
+Touchpad: 30.64% BAT 02:09:32
diff --git a/testcases/015-battery-capacity/i3status.conf b/testcases/015-battery-capacity/i3status.conf
new file mode 100644
index 0000000..60e626f
--- /dev/null
+++ b/testcases/015-battery-capacity/i3status.conf
@@ -0,0 +1,13 @@
+general {
+ output_format = "none"
+}
+
+order += "battery 1"
+
+battery 1 {
+ format = "Touchpad: %percentage %status %remaining"
+ format_down = "No touchpad"
+ path = "/sys/class/power_supply/hid-ff:ff:ff:ff:ff:ff-battery/uevent"
+ path = "testcases/015-battery-capacity/uevent"
+ low_threshold = 10
+}
diff --git a/testcases/015-battery-capacity/uevent b/testcases/015-battery-capacity/uevent
new file mode 100644
index 0000000..ac74624
--- /dev/null
+++ b/testcases/015-battery-capacity/uevent
@@ -0,0 +1,10 @@
+POWER_SUPPLY_CAPACITY=100
+POWER_SUPPLY_CURRENT_NOW=1107000
+POWER_SUPPLY_CHARGE_FULL_DESIGN=7800000
+POWER_SUPPLY_CHARGE_NOW=2390000
+POWER_SUPPLY_NAME=hid-70:cd:60:f7:a0:5c-battery
+POWER_SUPPLY_PRESENT=1
+POWER_SUPPLY_ONLINE=1
+POWER_SUPPLY_MODEL_NAME=applemagictrackpad
+POWER_SUPPLY_STATUS=Discharging
+POWER_SUPPLY_SCOPE=Device