Fix issue with test breakage when using canvas on qgis api. See #924
Merge pull request #930 from timlinux/pull-924

Fix issue with test breakage when using canvas on qgis api. See #924