docs: standard test version, link standard test guide

This commit is contained in:
Erick Friis 2024-11-15 14:54:21 -08:00
parent 709c418022
commit 53513c113c
3 changed files with 15 additions and 4 deletions

View File

@ -67,7 +67,7 @@ As a prerequisite to adding your integration to our documentation, you must:
1. Confirm that your integration is in the list of components we are currently accepting. 1. Confirm that your integration is in the list of components we are currently accepting.
2. Ensure that your integration is in a separate package that can be installed with `pip install <your-package>`. 2. Ensure that your integration is in a separate package that can be installed with `pip install <your-package>`.
3. Implement the standard tests for your integration and successfully run them. 3. Implement the standard tests for your integration and successfully run them (see [how-to guide](./standard_tests.ipynb))
3. Write documentation for your integration in the `docs/docs/integrations` directory of the LangChain monorepo. 3. Write documentation for your integration in the `docs/docs/integrations` directory of the LangChain monorepo.
4. Add a provider page for your integration in the `docs/docs/integrations/providers` directory of the LangChain monorepo. 4. Add a provider page for your integration in the `docs/docs/integrations/providers` directory of the LangChain monorepo.

View File

@ -15,7 +15,7 @@
"First, let's install 2 dependencies:\n", "First, let's install 2 dependencies:\n",
"\n", "\n",
"- `langchain-core` will define the interfaces we want to import to define our custom tool.\n", "- `langchain-core` will define the interfaces we want to import to define our custom tool.\n",
"- `langchain-tests==0.3.0` will provide the standard tests we want to use.\n", "- `langchain-tests==0.3.1` will provide the standard tests we want to use.\n",
"\n", "\n",
":::note\n", ":::note\n",
"\n", "\n",
@ -26,7 +26,7 @@
"or in a new release of `langchain-tests`.\n", "or in a new release of `langchain-tests`.\n",
"\n", "\n",
"Because added tests in new versions of `langchain-tests` will always break your CI/CD pipelines, we recommend pinning the \n", "Because added tests in new versions of `langchain-tests` will always break your CI/CD pipelines, we recommend pinning the \n",
"version of `langchain-tests==0.3.0` to avoid unexpected changes.\n", "version of `langchain-tests==0.3.1` to avoid unexpected changes.\n",
"\n", "\n",
":::" ":::"
] ]
@ -37,7 +37,7 @@
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
"%pip install -U langchain-core langchain-tests==0.3.0 pytest pytest-socket" "%pip install -U langchain-core langchain-tests==0.3.1 pytest pytest-socket"
] ]
}, },
{ {

View File

@ -0,0 +1,11 @@
try:
import tomllib
except ImportError:
# if prior to 3.11, use alternative toml library
import toml as tomllib
def test_cli_template_version() -> None:
"""
Confirm that the version in the CLI pyproject file is the same as the version in the package.
"""