#33906: TestCase inconsistent behavior on Db integrity error
-------------------------------------+-------------------------------------
Reporter: an-mile | Owner: nobody
Type: Bug | Status: new
Component: Testing framework | Version: 4.0
Severity: Normal | Resolution:
Keywords: testsuite | Triage Stage:
integrityError bug inconsistent | Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by an-mile):
I'm sorry for creating confusion with "NammeErrorWouldRaiseHere", but the
whole bug is just sooo weird to me that I just added some elementary
NameErrors, **print** and the like, just to make sure that I am not wrong
...
Replying to [comment:5 an-mile]:
> Replying to [comment:3 Mariusz Felisiak]:
> > Thanks for this report, however I don't see any issue here. You raised
`NameError` before trying to insert a new row to the database
(`bulk_create()` call is where we hit the database), that's why
`IntegrityError` is not raised.
> >
>
> hi,
>
> Unfortunately you did not understand the issue: the NameError is not the
issue at all, it was just added to illustrate different behavior between
the two different situations.
> The `bulk_create` is executed, raises an exception, but is then somehow
captured by the test suite or so, and the the execution of the test goes
on... Just weird...
--
Ticket URL: <https://code.djangoproject.com/ticket/33906#comment:6>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/010701827cb773cd-dae35874-75b8-4db1-bfc9-7f32c0fdbc82-000000%40eu-central-1.amazonses.com.