def METHOD_NAME(fwp, tvars):
    """Test flow for G0W0 calculations."""
    scf, nscf, scr, sig = make_g0w0_inputs(ngkpt=[2, 2, 2], tvars=tvars)
    flow = flowtk.g0w0_flow(fwp.workdir, scf, nscf, scr, sig, manager=fwp.manager)
    # Will remove output files at run-time.
    flow.set_garbage_collector()
    flow.build_and_pickle_dump(abivalidate=True)
    for task in flow[0]:
        task.start_and_wait()
    flow.check_status(show=True)
    assert all(work.finalized for work in flow)
    if not flow.all_ok:
        flow.debug()
        raise RuntimeError()
    scf_task = flow[0][0]
    nscf_task = flow[0][1]
    scr_task = flow[0][2]
    sig_task = flow[0][3]
    # Test garbage_collector
    # The WFK|SCR file should have been removed because we call set_garbage_collector
    assert not scf_task.outdir.has_abiext("WFK")
    assert not nscf_task.outdir.has_abiext("WFK")
    assert not scr_task.outdir.has_abiext("SCR")
    assert not scr_task.outdir.has_abiext("SUS")
    # The sigma task should produce a SIGRES file.
    sigfile = sig_task.outdir.list_filepaths(wildcard="*SIGRES.nc")[0]
    assert sigfile
    with abilab.abiopen(sigfile) as sigres:
        sigres.to_string(verbose=2)
        assert sigres.nsppol == 1
    # Test SigmaTask inspect method
    #if has_matplotlib():
        #sig_task.inspect(show=False)
    # Test get_results for Sigma and Scr
    scr_task.get_results()
    sig_task.get_results()
    # Test SCR.nc file (this is optional)
    if scr_task.scr_path:
        with scr_task.open_scr() as scr:
            scr.to_string(verbose=2)
            assert len(scr.wpts) == 2
            assert scr.nwre == 1 and scr.nwim == 1
            for iq, qpoint in enumerate(scr.qpoints[:2]):
                #print(qpoint)
                qpt, iqcheck = scr.reader.find_qpoint_fileindex(qpoint)
                assert iqcheck == iq
                em1 = scr.get_em1(qpoint)
                #print(em1)
    # TODO Add more tests
    #assert flow.validate_json_schema()