def unroll_extras(requirement):
    """Unroll extra requirements

        >>> unroll_extras('zope.foo')
        ['zope.foo']

        >>> unroll_extras('zope.foo[docs]')
        ['zope.foo', 'zope.foo[docs]']

        >>> unroll_extras('zope.foo[docs,tests]')
        ['zope.foo', 'zope.foo[docs]', 'zope.foo[tests]']

        >>> unroll_extras('zope.foo [ docs , tests ] ')
        ['zope.foo', 'zope.foo[docs]', 'zope.foo[tests]']

    """
    base, _, extras = requirement.partition('[')
    base = base.strip()
    extras = extras.partition(']')[0].strip().split(',') if extras else []
    requirements = [base]
    for extra in extras:
        requirements.append(base + '[' + extra.strip() + ']')
    return requirements