src/canvas-extractor/tests/data_generation/courses.py
def rollback_loaded_courses(courses: List[Course]):
    """
    Delete already loaded courses via the Canvas API.
    **** Used during testing of the load functionality ****

    Parameters
    ----------
    courses: List[Course]
        A list of Course SDK objects from a successful load operation
    """
    logger.info(
        "**** Rolling back %s courses via Canvas API - for testing purposes",
        len(courses),
    )

    for course in courses:
        course.delete()

    logger.info("**** Successfully deleted %s courses", len(courses))

    Delete already loaded courses via the Canvas API.
    **** Used during testing of the load functionality ****

    Parameters
    ----------
    courses: List[Course]
        A list of Course SDK objects from a successful load operation
    
Delete already loaded courses via the Canvas API.
Used during testing of the load functionality

Parameters

List[Course]
A list of Course SDK objects from a successful load operation
Delete already loaded courses via the Canvas API . Used during testing of the load functionality Parameters List [ Course ] A list of Course SDK objects from a successful load operation
def rollback_loaded_courses(courses: List[Course]):
    logger.info(
        "**** Rolling back %s courses via Canvas API - for testing purposes",
        len(courses),
    )
    for course in courses:
        course.delete()
    logger.info("**** Successfully deleted %s courses", len(courses))
def rollback_loaded_courses ( courses : List [ Course ] ) : logger . info ( "**** Rolling back %s courses via Canvas API - for testing purposes" , len ( courses ) , ) for course in courses : course . delete ( ) logger . info ( "**** Successfully deleted %s courses" , len ( courses ) )
Delete already loaded courses via the Canvas API.
Delete already loaded courses via the Canvas API .
"""
    Delete already loaded courses via the Canvas API.
    **** Used during testing of the load functionality ****

    Parameters
    ----------
    courses: List[Course]
        A list of Course SDK objects from a successful load operation
    """
courses
List[Course]