code: def test_calls_callback_on_change(app: Page):
      """Test that it correctly calls the callback on change."""
      text_input_field = (
          app.get_by_test_id("stTextInput")
          .nth(8)
          .locator("input")
          .first
      )
  
      text_input_field.fill("hello world")
      text_input_field.press("Enter")
  
      expect(app.get_by_test_id("stMarkdown").nth(8)).to_have_text(
          "value 9: hello world",
          use_inner_text=True,
      )
      expect(app.get_by_test_id("stMarkdown").nth(9)).to_have_text(
          "text input changed: True",
          use_inner_text=True,
      )
  
      # Change differentwidget to trigger delta path change
      first_text_input_field = (
          app.get_by_test_id("stTextInput").first.locator("input").first
      )
      first_text_input_field.fill("hello world")
      first_text_input_field.press("Enter")
  
      expect(app.get_by_test_id("stMarkdown").first).to_have_text(
          "value 1: hello world", use_inner_text=True
      )
  
      # Test if value is still correct after delta path change
      expect(app.get_by_test_id("stMarkdown").nth(8)).to_have_text(
          "value 9: hello world",
          use_inner_text=True,
      )
      expect(app.get_by_test_id("stMarkdown").nth(9)).to_have_text(
          "text input changed: False",
          use_inner_text=True,
      )
  
file_path: streamlit/e2e_playwright/st_text_input_test.py
imports: from playwright.sync_api import Page, expect
  from e2e_playwright.conftest import ImageCompareFunction
label_desc: Use image node_id 9 for calling a global function with example usage: test_calls_callback_on_change(app) without return types