domain: chatgpt.com
cases:
  # Same Draft.js-style trap as x.com: the composer is a ProseMirror
  # contenteditable, not a textarea. form_input silently fails; the agent
  # must use execCommand('insertText'). Typing into an in-app editor is the
  # most common real use case, so this case has high signal on adherence.
  - id: composer-uses-execcommand
    task: |
      Go to https://chatgpt.com/ and type the text "draft only — do not send"
      into the main chat composer. Do NOT click the Send button. After the
      text appears in the composer, return the word "TYPED".
    url: "https://chatgpt.com/"
    success_check:
      type: agent_answer_contains
      substring: "TYPED"
    forbidden_tool_call:
      tool: form_input
    required_tool_call:
      tool: javascript_tool
      body_contains: "execCommand"
    timeout_sec: 180
