Fix & improve units test (#1603)

7 jobs for master in 10 minutes and 48 seconds (queued for 2 seconds)
Status Job ID Name Coverage
  Build
passed #9886
build_bionic

00:03:05

passed #9882
build_buster

00:03:14

passed #9881
build_stretch

00:03:21

failed #9883
build_bionic

00:02:27

 
  Sign
passed #9884
sign

00:00:33

 
  Deploy
passed #9885
pages

00:00:34

passed pages:deploy

00:00:01