##### SUMMARY

Support collection roles as integration test targets.

Now that https://github.com/ansible/ansible/issues/59462 has been merged, ansible-test can be updated to support running integration test targets that are collection roles.

The planned convention is to look for targets under `roles/test/` and allow use of target-specific plugins from `plugins/{plugin_type}/test/{target_name}/`.

##### ISSUE TYPE

Feature Idea

##### COMPONENT NAME

ansible-test

##### ADDITIONAL INFORMATION

This will allow integration test targets to be written using collections instead of pre-collection roles.
if not codes:
                self.parse_errors.append((line_no, len(path), "Error code required after path"))
                continue
            code = codes[0]
            if not code:
                self.parse_errors.append((line_no, len(path) + 1, "Error code after path cannot be empty"))
                continue
            if len(codes) > 1:
                self.parse_errors.append((line_no, len(path) + len(code) + 2, "Error code cannot contain spaces"))
                continue
            parts = code.split('!')
            code = parts[0]
            commands = parts[1:]
            parts = code.split(':')
            test_name = parts[0]
            error_codes = parts[1:]
            test = tests_by_name.get(test_name)
            if not test:
                unversioned_name = unversioned_test_names.get(test_name)
                if unversioned_name:
                    self.parse_errors.append((line_no, len(path) + len(unversioned_name) + 2, "Sanity test '%s' cannot use a Python version like '%s'" % (
                        unversioned_name, test_name)))
                elif test_name in versioned_test_names:
                    self.parse_errors.append((line_no, len(path) + len(test_name) + 1, "Sanity test '%s' requires a Python version like '%s-%s'" % (
                        test_name, test_name, args.python_version)))
                else:
                    self.parse_errors.append((line_no, len(path) + 2, "Sanity test '%s' does not exist" % test_name))
                continue
            if path.endswith(os.path.sep) and not test.include_directories:
                self.parse_errors.append((line_no, 1, "Sanity test '%s' does not support directory paths" % test_name))