コード例 #1
0
ファイル: test_file.py プロジェクト: chaim1986/python-sdk
def test_acl():  # type: () -> None
    acl_ = ACL()
    f = File('Blah', io.BytesIO(b'xxx'))
    assert_raises(TypeError, f.set_acl, 'a')
    f.set_acl(acl_)
    assert f.get_acl() == acl_
コード例 #2
0
ファイル: test_file.py プロジェクト: fish-work/python-sdk
def test_acl():
    acl = ACL()
    f = File('blah', buffer('xxx'))
    f.set_acl(acl)
    assert f.get_acl() == acl
コード例 #3
0
ファイル: test_file.py プロジェクト: lord63-forks/python-sdk
def test_acl():
    acl = ACL()
    f = File('Blah', buffer('xxx'))
    assert_raises(TypeError, f.set_acl, 'a')
    f.set_acl(acl)
    assert f.get_acl() == acl
コード例 #4
0
ファイル: test_file.py プロジェクト: djun/python-sdk
def test_acl():  # type: () -> None
    acl_ = ACL()
    f = File("Blah", io.BytesIO(b"xxx"))
    assert_raises(TypeError, f.set_acl, "a")
    f.set_acl(acl_)
    assert f.get_acl() == acl_
コード例 #5
0
ファイル: test_file.py プロジェクト: leancloud/python-sdk
def test_acl():  # type: () -> None
    acl_ = ACL()
    f = File('Blah', io.BytesIO(b'xxx'))
    assert_raises(TypeError, f.set_acl, 'a')
    f.set_acl(acl_)
    assert f.get_acl() == acl_
コード例 #6
0
ファイル: test_file.py プロジェクト: JasonSam/python-sdk
def test_acl():
    acl = ACL()
    f = File('Blah', buffer_type(b'xxx'))
    assert_raises(TypeError, f.set_acl, 'a')
    f.set_acl(acl)
    assert f.get_acl() == acl
コード例 #7
0
ファイル: test_file.py プロジェクト: wujiangwei/python-sdk
def test_acl():
    acl = ACL()
    f = File('Blah', buffer('xxx'))
    f.set_acl(acl)
    assert f.get_acl() == acl