GoogleGoogle Professional Cloud Developer (PCD) Certification·EN·Updated 3 Sep 2026
You’re developing a Cloud Function triggered by Cloud Storage events and want faster local testing following Google best practices. What should you do?
Choose an answer
Tap an option to check your answer.
Correct answer: Install the Functions Frameworks library, and configure the Cloud Function on localhost. Make a copy of the function, and make edits to the new version. Test the new version using curl..
Why this is the answer
The Functions Frameworks library allows you to run Cloud Functions locally, simulating the Cloud Functions environment. This enables rapid iteration and testing without deploying to Google Cloud. You can then use curl or similar tools to send mock Cloud Storage event payloads to your local function.
The other options are less efficient or follow poor practices:
Rewriting to HTTP-triggered functions for testing adds unnecessary complexity and doesn't accurately test the Cloud Storage trigger logic.
Using Cloud Audit Logs to trigger another function is an overly complex and indirect testing method.
Testing in production by modifying a web application is highly discouraged as it introduces risk and is not a local testing strategy.