def test_basic_post():
    post = Post(label='1', role='Representative', organization_id='fake_org')
    assert '1' in str(post)
    post.validate()
示例#2
0
def test_basic_post():
    post = Post(label='1', role='Representative', organization_id='fake_org')
    assert '1' in str(post)
    post.validate()
def test_basic_invalid_post():
    post = Post(label=1, role='Representative', organization_id='fake_org')
    with pytest.raises(ValueError):
        post.validate()
示例#4
0
def test_basic_invalid_post():
    post = Post(label=1, role='Representative', organization_id='fake_org')
    with pytest.raises(ValueError):
        post.validate()
示例#5
0
def test_basic_post():
    post = Post('1', 'Representative', 'fake_org')
    assert '1' in str(post)
    post.validate()
示例#6
0
def test_basic_invalid_post():
    post = Post(1, 'Representative', 'fake_org')
    with pytest.raises(ValueError):
        post.validate()
示例#7
0
def test_basic_post():
    post = Post('1', 'Representative', 'fake_org')
    assert '1' in str(post)
    post.validate()
示例#8
0
def test_basic_invalid_post():
    post = Post(1, 'Representative', 'fake_org')
    with pytest.raises(ValueError):
        post.validate()