예제 #1
0
def test_fails_without_arguments():
    with pytest.raises(SystemExit):
        mdpants.parse_args([])
예제 #2
0
def test_binfile_needs_argument():
    with pytest.raises(SystemExit):
        assert mdpants.parse_args(['--bin'])
예제 #3
0
def test_infile_and_binary_fails():
    with pytest.raises(SystemExit):
        assert mdpants.parse_args(
            ['--in existing_file', '--bin existing_file'])
예제 #4
0
def test_random_and_file_fails():
    with pytest.raises(SystemExit):
        assert mdpants.parse_args(['-R', 'existing_file'])
예제 #5
0
def test_single_file_succesds():
    assert mdpants.parse_args(['existing_file'])
예제 #6
0
def test_just_random_succesds():
    assert mdpants.parse_args(['-R'])