Azure / Azure/azure-functions-java-worker

Provide access to settings through context parameter

Ouverte
#281 2 commentaires 0 réactions 1 personne assignée Réclamée par @kamperiadis Voir sur GitHub
area:java-functions New Feature reviewed
Langage dominant
Java
Étoiles
103
Forks
74
Merge moyen
4 j 8 h
PR mergées (30 j)
2

Description

Currently it is hard to unit test a function that uses an app setting by reading it from the environment variables. It would be much easier if there was a getSetting(settingName) method on the context parameter, as the context parameter can be mocked in unit tests. At runtime the host can continue to read the value from an environment variable via the method in the context parameter, so there wouldn't be any breaking changes to the runtime.

Guide de contribution

Ouvrir le guide de contribution

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.