Fix unit tests failed
Fix unit tests failed

if flow is None for add_tasks when running unit tests,
the method 'add' for flow  will be failed. this patch
will fix it.

Change-Id: I1bd70cea69cc54bea34de4b655f6d7caecfdf0e2

openstack/smaug,openstack/smaug