def attr(*args, **kwargs):
    """Decorator that adds attributes to classes or functions
    for use with the Attribute (-a) plugin.
    """

def wrap_ob(ob):
    for name in args:
        setattr(ob, name, True)
for name, value in kwargs.items():
    setattr(ob, name, value)
return ob
return wrap_ob
How do I write a nose2 plugin that seperates different types of tests?