'Checks that actual table is expected one.
Items to compare: \'next\' and \'prev\' links, count of rows and names of
elements in list
:param expected_table_definition: expected values (dictionary)
:param sorting: boolean arg specifying whether to sort actual names
:return:'

def assert_definition(self, expected_table_definition, sorting=False):

    names = [row.cells['name'].text for row in self.rows]
    if sorting:
        names.sort()
    actual_table = {'Next': self.is_next_link_available(), 'Prev': self.is_prev_link_available(), 'Count': len(self.rows), 'Names': names}
    self.assertDictEqual(actual_table, expected_table_definition)
