class_docstr: Tests for logging integration
docstr: Test logging of QNode forward pass
code: def test_dq_qnode_execution(self, caplog):
      "Test logging of QNode forward pass"
  
      enable_and_configure_logging()
  
      dev = qml.device("default.qubit", wires=2)
  
      with caplog.at_level(logging.DEBUG):
          dev = qml.device("default.qubit", wires=2)
          params = qml.numpy.array(0.1234)
  
          @qml.qnode(dev, diff_method=None)
          def circuit(params):
              qml.RX(params, wires=0)
              return qml.expval(qml.PauliZ(0))
  
          circuit(params)
  
      assert len(caplog.records) == 4
  
      log_records_expected = [
          (
              "pennylane.workflow.qnode",
              [
                  "Creating QNode(func=<function TestLogging.test_dq_qnode_execution"
              ],
          ),
          (
              "pennylane.workflow.execution",
              [
                  "device=<default.qubit device (wires=2)",
                  "gradient_fn=None, interface=None",
              ],
          ),
      ]
  
      for expected, actual in zip(
          log_records_expected, caplog.records[:2]
      ):
          assert expected[0] in actual.name
          assert all(msg in actual.getMessage() for msg in expected[1])
  
file_path: pennylane/tests/logging/test_logging_autograd.py
imports: import logging
  import pytest
  import pennylane
  import pennylane.logging
label_desc: Use image node_id 2 for calling the TestLogging obj's underlying member method code with example usage: obj.test_dq_qnode_execution(caplog) and returns: qml