Exemplo n.º 1
0
    def test_invalid_file(self):
        invalid_file = "Tests/images/flower.jpg"

        self.assertRaises(SyntaxError,
                          lambda: PsdImagePlugin.PsdImageFile(invalid_file))
Exemplo n.º 2
0
def test_invalid_file():
    invalid_file = "Tests/images/flower.jpg"

    with pytest.raises(SyntaxError):
        PsdImagePlugin.PsdImageFile(invalid_file)