IMPALA-5246: Verify that a UDF test completely finishes before moving on
IMPALA-5246: Verify that a UDF test completely finishes before moving on

A memory intensive UDF test takes a while to completely finish and for
the memory in Impala to be completely freed. This caused a problem in
ASAN builds (and potentially in normal builds) because we would start
the next test right away, before the memory is freed.

We fix the issue by checking that all fragments finish executing before
starting the next test.

Testing:
- Ran a private ASAN build which passed.

Change-Id: I0555b5327945c522f70f449caa1214ee0bfd84fe
Reviewed-on: http://gerrit.cloudera.org:8080/6893
Reviewed-by: Alex Behm <fe1626037acfc2dc542d2aa723a6d14f2464a20c@cloudera.com>
Reviewed-by: Michael Ho <43544f6c6f19372b140301f92a3768afc300868a@cloudera.com>
Tested-by: Impala Public Jenkins

cloudera/Impala,cloudera/Impala,cloudera/Impala,cloudera/Impala,cloudera/Impala,cloudera/Impala,cloudera/Impala