drm-tests: add test_commit() before committing planes

This patch adds test_and_commit() helper function
that checks test_commit() before calling commits to
avoid failures

BUG=b:65297611
TEST=On Kahlee verified that atomictest -t all pass

Change-Id: Ia82a5d38b8e4ff83448f4cba5c91404d90b89ecb
Signed-off-by: Shirish S <shirish.s@amd.com>
Reviewed-on: https://chromium-review.googlesource.com/937105
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
2 files changed