| 1 |
This subtree contains the daemon for notifying of successful print jobs, |
| 2 |
and of issues with the printer when jobs are printed, under Unity 8. |
| 3 |
This document describes how to test some notifications. |
| 4 |
|
| 5 |
|
| 6 |
Testing |
| 7 |
|
| 8 |
0) Make sure the notifier daemon is running: |
| 9 |
|
| 10 |
$: ./build/notifier/src/printing-notifier-service |
| 11 |
|
| 12 |
1) Add a null printer, if one is not already configured, and enable it: |
| 13 |
|
| 14 |
$: lpadmin -p nulldevice -E -v file:///dev/null |
| 15 |
$: cupsenable nulldevice |
| 16 |
|
| 17 |
2) Print a test page: |
| 18 |
|
| 19 |
$: lpr -P nulldevice -J "Test Page" /usr/share/cups/data/default-testpage.pdf |
| 20 |
|
| 21 |
The document should "print" immediately, and you should get a notification |
| 22 |
that reads '"Test Page" has printed." |
| 23 |
|
| 24 |
3) Pause the printer, print another test page, and emit the PrinterStateChanged |
| 25 |
signal over dbus: |
| 26 |
|
| 27 |
$: cupsdisable nulldevice |
| 28 |
$: lpr -P nulldevice -J "Test Page" /usr/share/cups/data/default-testpage.pdf |
| 29 |
$: gdbus emit -y -o /org/cups/cupsd/Notifier \ |
| 30 |
-s org.cups.cupsd.Notifier.PrinterStateChanged \ |
| 31 |
"Some text" "cups://nulldevice" "nulldevice" 'uint32 0' "toner-low" true |
| 32 |
|
| 33 |
You should see a notification for the toner being low, with one job |
| 34 |
queued on the printer. Clicking the OK button should close the notification |
| 35 |
and perform no further actions. Clicking the "Settingsā¦" button should |
| 36 |
cause system-settings to open to the settings page for that particular |
| 37 |
printer. |