Exemplo n.º 1
0
def extract(tmpdir, distorted_diamond, pwscf):
    from pylada.espresso.tests.bdd.fixtures import copyoutput, data_path
    src = data_path("restarted", "first")
    tmpdir.join("first", "Si.pz-vbc.UPF").ensure(file=True)
    program = copyoutput(
        tmpdir.join("first_copy.py"), src, tmpdir.join("first"))
    return pwscf(distorted_diamond, tmpdir.join("first"), program=str(program))
Exemplo n.º 2
0
def extract(tmpdir, distorted_diamond, pwscf):
    from pylada.espresso.tests.bdd.fixtures import copyoutput, data_path
    src = data_path("restarted", "first")
    tmpdir.join("first", "Si.pz-vbc.UPF").ensure(file=True)
    program = copyoutput(tmpdir.join("first_copy.py"), src,
                         tmpdir.join("first"))
    return pwscf(distorted_diamond, tmpdir.join("first"), program=str(program))
Exemplo n.º 3
0
def run_second(tmpdir, extract, pwscf, distorted_diamond, passon):
    from pylada.espresso.tests.bdd.fixtures import copyoutput, data_path
    assert extract.input_path == tmpdir.join("first", "pwscf.in")
    assert extract.output_path == tmpdir.join("first", "pwscf.out")
    assert extract.success
    pwscf.control.calculation = None
    src = data_path("restarted", "second")
    tmpdir.join("second", "Si.pz-vbc.UPF").ensure(file=True)
    program = copyoutput(tmpdir.join("second_copy.py"), src, tmpdir.join("second"))
    passon.append(pwscf(distorted_diamond, tmpdir.join("second"), restart=extract,
                        program=str(program)))
Exemplo n.º 4
0
def run_second(tmpdir, extract, pwscf, distorted_diamond, passon):
    from pylada.espresso.tests.bdd.fixtures import copyoutput, data_path
    assert extract.input_path == tmpdir.join("first", "pwscf.in")
    assert extract.output_path == tmpdir.join("first", "pwscf.out")
    assert extract.success
    pwscf.control.calculation = None
    src = data_path("restarted", "second")
    tmpdir.join("second", "Si.pz-vbc.UPF").ensure(file=True)
    program = copyoutput(tmpdir.join("second_copy.py"), src,
                         tmpdir.join("second"))
    passon.append(
        pwscf(distorted_diamond,
              tmpdir.join("second"),
              restart=extract,
              program=str(program)))
Exemplo n.º 5
0
def run_nonscf(tmpdir, aluminum, pwscf, passon):
    from pylada.espresso.tests.bdd.fixtures import copyoutput, data_path
    src = data_path("nonscf")
    program = copyoutput(tmpdir, src, tmpdir)
    passon.append(pwscf(aluminum, tmpdir, program=str(program)))
Exemplo n.º 6
0
def run_nonscf(tmpdir, aluminum, pwscf, passon):
    from pylada.espresso.tests.bdd.fixtures import copyoutput, data_path
    src = data_path("nonscf")
    program = copyoutput(tmpdir, src, tmpdir)
    passon.append(pwscf(aluminum, tmpdir, program=str(program)))