Google Cloud Professional Machine Learning Engineer — Question 36

You have written unit tests for a Kubeflow Pipeline that require custom libraries. You want to automate the execution of unit tests with each new push to your development branch in Cloud Source Repositories. What should you do?

Answer options

Correct answer: B

Explanation

The correct answer is B because Cloud Build is specifically designed to automate the execution of tasks such as running unit tests upon code changes in Cloud Source Repositories. Option A lacks automation for triggering tests upon pushes, while options C and D involve additional steps and components that complicate the process unnecessarily compared to the direct approach of using Cloud Build.