Esempio n. 1
0
def test_insert_empty():
    doubly_linked_list = DoublyLinkedList()
    doubly_linked_list.insert(3, 0)
    assert doubly_linked_list.size() == 1
    assert doubly_linked_list.get(0) == 3
Esempio n. 2
0
def test_get_node():
    doubly_linked_list = DoublyLinkedList()
    doubly_linked_list.insert(3, 0)
    assert doubly_linked_list.get_node(0).data == 3