def METHOD_NAME(testdir):
    run_test_code(
        testdir,
        """
    from ophyd import EpicsSignal
    from ophyd.signal import EpicsSignalBase
    pv_base = "%s"
    def test_without_defaults_no_string():
        EpicsSignalBase.set_defaults(
            write_timeout=60,
        )
        signal = EpicsSignal(f"{pv_base}.SCAN", name="signal", string=True)
        signal.wait_for_connection()
        desc = signal.describe()
        assert signal.as_string
        assert desc["signal"]["dtype"] == "string"
    """
        % pv_base,
    )