Beispiel #1
0
def test_Selection_output_data_setter():
    alg = MockConfGenerator()
    sel0 = AutomaticData('Phys/Hello/World/0')
    sel1 = AutomaticData('Phys/Hello/World/1')
    sel = Selection('SelOutputTest6',
                    ConfGenerator=alg,
                    RequiredSelections=[sel0, sel1])
    assert sel.algorithm().Output == sel.outputLocation()
Beispiel #2
0
def test_Selection_outputLocation_with_no_branch_and_no_extension():
    alg = MockConfGenerator()
    sel = Selection('SelOutputTest4',
                    ConfGenerator=alg,
                    OutputBranch='',
                    Extension='')
    assert sel.outputLocation() == 'SelOutputTest4'
    assert sel.outputLocation() == sel.algorithm().Output
Beispiel #3
0
def test_Selection_outputLocation_with_user_defined_extension_and_no_branch():
    alg = MockConfGenerator()
    sel = Selection('SelOutputTest3',
                    ConfGenerator=alg,
                    OutputBranch='',
                    Extension='Tracks')
    assert sel.outputLocation() == 'SelOutputTest3/Tracks'
    assert sel.outputLocation() == sel.algorithm().Output
Beispiel #4
0
def test_Selection_with_user_defined_output_data_setter():
    alg = MockConfGenerator()
    sel0 = AutomaticData('Phys/Hello/World/0')
    sel1 = AutomaticData('Phys/Hello/World/1')
    sel = Selection('SelOutputTest8',
                    ConfGenerator=alg,
                    RequiredSelections=[sel0, sel1],
                    OutputDataSetter='TESTOUTPUTS')
    assert sel.algorithm().TESTOUTPUTS == sel.outputLocation()
Beispiel #5
0
def test_Selection_outputLocation():
    alg = MockConfGenerator()
    sel = Selection('SelOutputTest0', ConfGenerator=alg)
    assert sel.outputLocation() == 'Phys/SelOutputTest0/Particles'
    assert sel.outputLocation() == sel.algorithm().Output