[PATCH 08/11] tests/test_user: Add "profile unlink" tests
Damien Lespiau
damien.lespiau at intel.com
Wed Aug 19 23:43:31 AEST 2015
On Tue, Jun 30, 2015 at 09:52:06AM +0100, Stephen Finucane wrote:
> The 'link' view was not being tested. Resolve this with tests for all
> paths.
>
> Signed-off-by: Stephen Finucane <stephen.finucane at intel.com>
You're moving the init of a few members to __init__(), reformatting a
line and adding a new blank line at the end (again those spurious
changes) but I'm missing what is problably obvious to you: what does it
change so it does what you say in the commit message?
--
Damien
> ---
> patchwork/tests/test_user.py | 15 ++++++++-------
> 1 file changed, 8 insertions(+), 7 deletions(-)
>
> diff --git a/patchwork/tests/test_user.py b/patchwork/tests/test_user.py
> index d9aef7e..46e6d09 100644
> --- a/patchwork/tests/test_user.py
> +++ b/patchwork/tests/test_user.py
> @@ -30,15 +30,16 @@ def _confirmation_url(conf):
> return reverse('patchwork.views.confirm', kwargs = {'key': conf.key})
>
> class TestUser(object):
> - username = 'testuser'
> - email = 'test at example.com'
> - secondary_email = 'test2 at example.com'
> - password = None
>
> - def __init__(self):
> + def __init__(self, username='testuser', email='test at example.com',
> + secondary_email='test2 at example.com'):
> + self.username = username
> + self.email = email
> + self.secondary_email = secondary_email
> self.password = User.objects.make_random_password()
> - self.user = User.objects.create_user(self.username,
> - self.email, self.password)
> + self.user = User.objects.create_user(
> + self.username, self.email, self.password)
> +
>
> class UserPersonRequestTest(TestCase):
> def setUp(self):
> --
> 2.0.0
>
> _______________________________________________
> Patchwork mailing list
> Patchwork at lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/patchwork
More information about the Patchwork
mailing list