Makes tasks owner not nullable in models.py

The tasks table scheme in migration for adding tasks to Glance DB has a
flag for disabling from setting a NULL owner.

In order to keep the behavior consistent across the glance codebase,
this patch adds owner as not nullable in the models.py.

Fixes bug: 1257949

Change-Id: Id9fff4277f427b7d83d80b5a0a8029968f70e0df
Unittests added for glance/cmd/cache_manage.py

Related to blueprint glance-cmd+unittests

Unittests for all methods, that manage cache added:
* list_cached
* list_queued
* queue_image
* delete_cached_image
* delete_all_cached_images
* delete_queued_image
* delete_all_queued_images

Unittests for several internal methods added:
catch_error; env; create_options; parse_options; lookup_command

Change-Id: Id07bbecdc9877268a514e3a594699364dcc4618f
Merge "Makes tasks owner not nullable in models.py"