code: def test_build_config_requirements_warns(monkeypatch, caplog):
      requirements = ["foo", "bar"]
      bc = BuildConfig(requirements=requirements)
      monkeypatch.setattr(
          bc, "_find_requirements", lambda *_, **__: ["baz"]
      )
      work = Mock()
      with caplog.at_level(logging.INFO):
          bc.on_work_init(work)
      assert (
          "requirements.txt' exists with ['baz'] but ['foo', 'bar']"
          in caplog.text
      )
      assert bc.requirements == requirements
  
imports: import logging
  import os
  import sys
  from unittest.mock import Mock
  from lightning.app.testing import LightningTestApp, application_testing
  from lightning.app.utilities.packaging.build_config import BuildConfig
  from tests_app import _TESTS_ROOT
label_desc: Use image node_id 7 for calling a global function with example usage: test_build_config_requirements_warns(monkeypatch, caplog) without return types