test_agenda_schedule.py 文件源码

python
阅读 21 收藏 0 点赞 0 评论 0

项目:pretalx 作者: pretalx 项目源码 文件源码
def test_orga_can_see_new_talk(orga_client, event, unreleased_slot):
    slot = unreleased_slot
    response = orga_client.get(slot.submission.urls.public, follow=True)
    assert event.schedules.count() == 1
    assert response.status_code == 200
    content = response.content.decode()
    assert content.count(slot.submission.title) >= 2  # meta+h1
    assert slot.submission.abstract in content
    assert slot.submission.description in content
    assert formats.date_format(slot.start, 'Y-m-d, H:i') in content
    assert formats.date_format(slot.end, 'H:i') in content
    assert str(slot.room.name) in content
    assert 'fa-pencil' not in content  # edit btn
    assert 'fa-video-camera' not in content  # do not record
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号