diff --git a/docs/contributing/unreleased-features.md b/docs/contributing/unreleased-features.md index df5099d2..00695a71 100644 --- a/docs/contributing/unreleased-features.md +++ b/docs/contributing/unreleased-features.md @@ -1,5 +1,8 @@ # Unreleased Features -Citric supports LimeSurvey features that are not yet released and are sitting in the [`master`](https://github.com/LimeSurvey/LimeSurvey/tree/master) or [`develop`] branches of the LimeSurvey repository. These features must be decorated with [citric._compat.future]`@future` in order to be warn users that they are using a feature that is not yet released. +Citric supports LimeSurvey features that are not yet released and are sitting in the [`master`](https://github.com/LimeSurvey/LimeSurvey/tree/master) or [`develop`](https://github.com/LimeSurvey/LimeSurvey/tree/develop) branches of the LimeSurvey repository. These features must be decorated with {func}`@future ` or {func}`@future_parameter ` in order to be warn users that they are using a feature that is not yet released. -The `.. future` directive will add a warning to the documentation. +There are also Sphinx directives that can be used to document these features: + +* The `.. future` directive will add a warning to the documentation that the method is not yet supported in any released version of LimeSurvey. +* The `.. futureparam` directive will add a warning to the documentation that the parameter is not yet supported in any released version of LimeSurvey. diff --git a/src/citric/_compat.py b/src/citric/_compat.py index 99212ab4..051cef40 100644 --- a/src/citric/_compat.py +++ b/src/citric/_compat.py @@ -6,7 +6,7 @@ import warnings from functools import wraps -__all__ = ["FutureVersionWarning", "future"] +__all__ = ["FutureVersionWarning", "future", "future_parameter"] def _warning_message(next_version: str) -> tuple[str, ...]: diff --git a/tests/resources/config.php b/tests/resources/config.php index 5afd7d42..faeec994 100644 --- a/tests/resources/config.php +++ b/tests/resources/config.php @@ -29,6 +29,14 @@ ), 'request' => array( 'baseUrl' => '', + // TODO: Remove 'noCsrfValidationRoutes' this once it's fixed upstream + // https://github.com/LimeSurvey/LimeSurvey/pull/3599 + 'enableCsrfValidation' => true, + 'noCsrfValidationRoutes' => array( + 'rest', + 'admin/remotecontrol', + 'plugins/unsecure', + ), ), ), 'config' => array(