From b7adfebe9cf9d8ba8ab7beabb1b97c8ae4ccd466 Mon Sep 17 00:00:00 2001 From: hjoaquim Date: Mon, 18 Sep 2023 17:34:12 +0100 Subject: [PATCH] readme --- openbb_sdk/providers/tests/README.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 openbb_sdk/providers/tests/README.md diff --git a/openbb_sdk/providers/tests/README.md b/openbb_sdk/providers/tests/README.md new file mode 100644 index 00000000000..36253cbaa26 --- /dev/null +++ b/openbb_sdk/providers/tests/README.md @@ -0,0 +1,15 @@ +# Providers unit tests + +In order to automatically generate unit tests for the providers you can run the following command: + +```bash +python openbb_sdk/providers/utils/unit_test_generator.py +``` + +> Note that you should be running this file from the root of the repository. + +The automatic unit test generation will add unit tests for all the fetchers available in a given provider. +Each provider will have one auto generated unit test file, and inside that file there will be one unit test for each fetcher. +If the fetcher was added at a later stage compared with the generation of the test file, one can run the script again and new fetchers only will be added. + +> Note that sometimes manual intervention can be needed, for example, adjusting out-of-top level imports or adding specific arguments for a given fetcher.