def test_when_file_is_created_its_contents_are_posted():
    tempdir = tempfile.mkdtemp()
    p = run_broadcaster(tempdir)
    r = get_async()
    create_image(tempdir, "channel", "JPEG IMAGE")
    p.terminate()
    buffer_size = 45
    assert "JPEG IMAGE" in r.get(timeout=2).read(buffer_size)
dataset/ETHPy150Open jbochi/live_thumb/tests/test_integration.py/test_when_file_is_created_its_contents_are_posted/original