예제 #1
0
파일: test_image.py 프로젝트: caelor/sigal
def test_generate_image_processor(tmpdir):
    "Test generate_image with a wrong processor name."

    init_logging()
    dstfile = str(tmpdir.join(TEST_IMAGE))
    with pytest.raises(SystemExit):
        generate_image(SRCFILE, dstfile, (200, 200), None,
                       method='WrongMethod')
예제 #2
0
파일: test_image.py 프로젝트: kuyan/sigal
def test_generate_image_processor(tmpdir):
    "Test generate_image with a wrong processor name."

    init_logging()
    dstfile = str(tmpdir.join(TEST_IMAGE))
    with pytest.raises(SystemExit):
        settings = create_settings(img_size=(200, 200), img_processor="WrongMethod")
        generate_image(SRCFILE, dstfile, settings)
예제 #3
0
def test_generate_image_processor(tmpdir):
    "Test generate_image with a wrong processor name."

    init_logging('sigal')
    dstfile = str(tmpdir.join(TEST_IMAGE))
    settings = create_settings(img_size=(200, 200),
                               img_processor='WrongMethod')

    with pytest.raises(SystemExit):
        generate_image(SRCFILE, dstfile, settings)