def test_buffer_saving(image_test):
    """Test colour buffer save.

    A scene consisting of a single coloured triangle will be rendered.  The
    colour buffer will then be saved to a stream and loaded as a texture.

    You might see the original scene first shortly before the
    buffer image appears (because retrieving and saving the image is a slow
    operation).
    """
    image_test.create_window(width=800, height=600)
    image_test.show_triangle_left = True
    image_test.show_text = False
    image_test.show_checkerboard = False

    def step(dt):
        image_test.save_and_load_color_buffer()
        image_test.show_text = True
        return True
    image_test.schedule_once(step)

    image_test.ask_question(
            'You should see the same coloured triangle left and right.'
            )