Testing Setup with Jest Configure Jest with Firebase Cloud Functions testing utilities.

This lesson is available for PRO members or as a single course purchase. Sign-in and choose a plan below.
Get Unlimited PRO Access

OR


*Enrollment provides full access to this course (and updates) for life.

file_type_typescript test-config.ts
import * as TestFunctions from 'firebase-functions-test';

const firebaseConfig = {
    databaseURL: "https://your-app.firebaseio.com",
    projectId: "your-app",
    storageBucket: "your-app.appspot.com",
}

const envConfig = { stripe: { secret: 'sk_test_yourkey' }};

const fun = TestFunctions(firebaseConfig, 'service-account.json')

fun.mockConfig(envConfig);

export { fun };

Questions?

Ask questions via GitHub below OR chat on Slack #questions