def METHOD_NAME(self, node: workermanage.WorkerController) -> None:
    """Assign a work unit to a node."""
    assert self.workqueue
    assigned_to_node = self.assigned_work.setdefault(node, default=collections.OrderedDict())
    scope, work_unit = None, None
    # check if there are any long-running tests already pending
    long_pending = self._is_long_pending(assigned_to_node)
    if long_pending:
        # try to find a work unit with no long-running test if there is already a long-running
        # test pending
        scope = self._get_short_scope()
        if scope:
            work_unit = self.workqueue.pop(scope)
    else:
        # Try to find a work unit with long-running test if there is no long-running test
        # pending. We want to schedule long-running tests as early as possible
        scope = self._get_long_scope()
        if scope:
            work_unit = self.workqueue.pop(scope)
    # grab the first unit of work if none was grabbed above
    if work_unit is None:
        scope, work_unit = self.workqueue.popitem(last=False)
    # keep track of the assigned work
    assigned_to_node[scope] = work_unit
    # ask the node to execute the workload
    worker_collection = self.registered_collections[node]
    nodeids_indexes = [
        worker_collection.index(nodeid)
        for nodeid, completed in work_unit.items()
        if not completed
    ]
    node.send_runtest_some(nodeids_indexes)