Skip to content

Test fails to run in the collections format if the role name contains '-' (dash) #10

@nhosoi

Description

@nhosoi

This is just a testing convenience, but if converted to the collections format, ci-testing/tests/tests_default.yml fails as follows:

ERROR! the role 'fedora.system_roles.ci-testing' was not found in /tmp/tmp4fnee3t7/tests/ci-testing/roles:~/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/tmp/tmp4fnee3t7/tests/ci-testing
The error appears to be in '/tmp/tmp4fnee3t7/tests/ci-testing/tests_default.yml': line 7, column 7, but may
be elsewhere in the file depending on the exact syntax problem.
The offending line appears to be:
  roles:
    - fedora.system_roles.ci-testing
      ^ here

If it's renamed to ci_testing, it passes.

Note: lsr_role2collection replaces '.' (dot) in a sub-role name, but '-' (dash) is not. Also, the main role names are not touched.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions