Home / Function/ test_custom_class_with_secret_dict() — langchain Function Reference

test_custom_class_with_secret_dict() — langchain Function Reference

Architecture documentation for the test_custom_class_with_secret_dict() function in test_secret_injection.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  d98dadfb_813b_c8df_fb5c_c01f95742efa["test_custom_class_with_secret_dict()"]
  ce66dbf1_8b97_04bf_88af_30bbaa94a5c9["TestNonSerializableClassTopLevel"]
  d98dadfb_813b_c8df_fb5c_c01f95742efa -->|defined in| ce66dbf1_8b97_04bf_88af_30bbaa94a5c9
  9667a3de_eb6c_d235_9e9f_0bb0ddcacee3["_assert_no_secret_leak()"]
  d98dadfb_813b_c8df_fb5c_c01f95742efa -->|calls| 9667a3de_eb6c_d235_9e9f_0bb0ddcacee3
  style d98dadfb_813b_c8df_fb5c_c01f95742efa fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/core/tests/unit_tests/load/test_secret_injection.py lines 232–240

    def test_custom_class_with_secret_dict(self) -> None:
        """Custom class containing a secret-like dict directly."""

        class MyClass:
            def __init__(self, data: dict[str, Any]) -> None:
                self.data = data

        payload = MyClass(data=MALICIOUS_SECRET_DICT)
        _assert_no_secret_leak(payload)

Domain

Subdomains

Frequently Asked Questions

What does test_custom_class_with_secret_dict() do?
test_custom_class_with_secret_dict() is a function in the langchain codebase, defined in libs/core/tests/unit_tests/load/test_secret_injection.py.
Where is test_custom_class_with_secret_dict() defined?
test_custom_class_with_secret_dict() is defined in libs/core/tests/unit_tests/load/test_secret_injection.py at line 232.
What does test_custom_class_with_secret_dict() call?
test_custom_class_with_secret_dict() calls 1 function(s): _assert_no_secret_leak.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free