Comment 1 for bug 1204528

Revision history for this message
Didier Roche-Tolomelli (didrocks) wrote :

1st case: static call: with the --testing=no-update, I think the different dbus method should returns statically:
(based on http://bazaar.launchpad.net/~ubuntu-system-image/ubuntu-system-image/client/view/head:/systemimage/dbus.py)

BuildNumber: 42 seems obligatory :p
IsUpdateAvailable: False
The other values seems not needed then, right?

2nd case: Success update: --testing=update-success:

BuildNumber: 42
IsUpdateAvailable: True
GetUpdateSize: 1337kB (so, I guess converted in bytes)
GetUpdateVersion: 44
GetDescriptions, should combine cases where we had descriptions on some language, but None on all updates, like:
[{'description': "Ubuntu Edge support", 'description-fr': "Support d'Ubuntu Edge"},
{'description': "Flipped container with 200% boot speed improvment"}]
Please note that the second update doesn't have french description on purpose (I think we should fallback to english in that case, which doesn't have any prefix, right?)
(btw, from that spec, is the list of descriptions ordered from older update to newest?)

GetUpdate(), well start a fake update :)
-> I think this should spawn some "progress" signal, with the bytes downloaded.

Then, after a while:
ReadyToReboot signal is triggered

Reboot: the call should succeed

If we trigger Cancel, it should:
- fail if GetUpdate() wasn't in progress
- trigger Canceled signal otherwise

* 3rd case, update download failed: --testing=update-success
Same values than before, apart that after calling GetUpdate(), UpdateFailed signal should be raised after few seconds (10s?)

* 4rd case: update available when daemon running: --testing=update-newpending (better name needed :p)
First call to IsUpdateAvailable: False
Then, UpdatePending signal raise after few seconds (10s?)
then calling IsUpdateAvailable returns True