services/device/deviced/internal/impl: fix restart policy and test

Change the logic in the restart policy implementation to match the
documentation: we should reset the restart time window with each restart.

Add a test case in the unit test to capture this behavior; also fix the unit
test comparison logic to correctly evaluate the RestartWindowBegan field (it was
always passing before).  As a consequence of fixing the comparison logic, a test
case needed updating.

Unrelated: add the app instance version's envelope in the Debug output for
convenience and add a couple todos for some issues noticed.

Change-Id: Idb6072354ad7f3920d9dd07fe30203a3596d6f43
4 files changed
tree: 231637e3cb63d486c3d7d7b015cd7f106e24ff6c
  1. cmd/
  2. examples/
  3. internal/
  4. lib/
  5. runtime/
  6. services/
  7. test/
  8. .gitignore
  9. AUTHORS
  10. CONTRIBUTORS
  11. envvar.go
  12. envvar_test.go
  13. LICENSE
  14. PATENTS
  15. README.md
  16. VERSION
README.md

Vanadium

This repository contains a reference implementation of the Vanadium APIs.

Unlike the APIs in https://github.com/vanadium/go.v23, which promises to provide backward compatibility this repository makes no such promises.