<commit_before>import linked_list as LL
import pytest
# import unittest


def test_init_Node():
    data = "test"
    head = LL.Node(data)
    assert type(head) == LL.Node
    assert head.data == data


def test_init_LinkedList():
    linked_list = LL.LinkedList()
    assert type(linked_list) == LL.LinkedList


def test_insert():
    linked_list = LL.LinkedList()
    data = "test"
    linked_list.insert(data)
    assert linked_list.head.data == data


def test_pop():
    linked_list = LL.LinkedList()
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    assert linked_list.pop() == 3


def test_size():
    linked_list = LL.LinkedList()
    assert linked_list.size() == 0
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    assert linked_list.size() == 3


def test_search():
    linked_list = LL.LinkedList()
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    find = linked_list.search(2)
    expected = (2)
    actual = (find)
    assert expected, actual


def test_remove():
    linked_list = LL.LinkedList()
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    node = linked_list.search(2)
    assert linked_list.remove(node) is not None
    assert linked_list.remove(node) == None


def test_display():
    linked_list = LL.LinkedList()
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    assert linked_list.display == "1, 2, 3"<commit_msg>corrected test for display<commit_after>import linked_list as LL
import pytest
# import unittest

def test_init_Node():
    data = "test"
    head = LL.Node(data)
    assert type(head) == LL.Node
    assert head.data == data


def test_init_LinkedList():
    linked_list = LL.LinkedList()
    assert type(linked_list) == LL.LinkedList


def test_insert():
    linked_list = LL.LinkedList()
    data = "test"
    linked_list.insert(data)
    assert linked_list.head.data == data


def test_pop():
    linked_list = LL.LinkedList()
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    assert linked_list.pop() == 3


def test_size():
    linked_list = LL.LinkedList()
    assert linked_list.size() == 0
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    assert linked_list.size() == 3


def test_search():
    linked_list = LL.LinkedList()
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    find = linked_list.search(2)
    expected = (2)
    actual = (find)
    assert expected, actual


def test_remove():
    linked_list = LL.LinkedList()
    linked_list.insert(1)
    linked_list.insert(2)
    linked_list.insert(3)
    node = linked_list.search(2)
    assert linked_list.remove(node) is not None
    assert linked_list.remove(node) == None


def test_display():
    linked_list = LL.LinkedList()
    linked_list.insert(3)
    linked_list.insert(2)
    linked_list.insert(1)
    assert linked_list.display() == "(1, 2, 3)"
{'fraction_non_alphanumeric': 0.11811546118115461, 'fraction_numerical': 0.015925680159256803, 'mean_word_length': 3.3506493506493507, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '725959', 'n_tokens_mistral': 1052, 'n_tokens_neox': 1026, 'n_words': 212}