New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable add_arguments on the runners to work #335
Comments
Oki I understand why this is not working: Django extends the Command using what is defined by the TEST_RUNNER config here: https://github.com/django/django/blob/master/django/core/management/commands/test.py#L56 But not by what is defined by the JENKINS_TASK_RUNNER. So the add_arguments on my class has no effect. How should we we fix this? |
I think my PR is working and is a decent solution. Do you need tests for this? |
Actually this is just wrong> Now I am running into troubles if I do this: JENKINS_TEST_RUNNER = 'lib.runner.TestRunner' The arguments are now added twice and it triggers an error it get the argument argparse.ArgumentError: argument --run-functionnal: conflicting option string(s): --run-functionnal |
Oki so now my runner looks like that
With those settings
And it seems to work again both with python manage.py test and python manage.py jenkins But this his convoluted |
A example is worth a thousand words. I would like to be able to use what is described in the Django documentation here about add_arguments(cls, parser):
https://docs.djangoproject.com/en/1.9/topics/testing/advanced/#django.test.runner.DiscoverRunner
Then I would like to run
python manage.py jenkins --func=yes
The text was updated successfully, but these errors were encountered: