Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2023-01-04 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  closed
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:  fixed
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Mariusz Felisiak ):

 In [changeset:"99bd5fb4c2d51f7bf8a19b2c12a603ab38b85ec9" 99bd5fb4]:
 {{{
 #!CommitTicketReference repository=""
 revision="99bd5fb4c2d51f7bf8a19b2c12a603ab38b85ec9"
 Refs #34074 -- Used headers argument for RequestFactory and Client in docs
 and tests.
 }}}

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/010701857bf27c9c-eedc38fd-cc85-46df-a980-e20e9493fa70-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-11-14 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  closed
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:  fixed
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak ):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"67da22f08e05018ea968fcacbac9ac37ea925d85" 67da22f]:
 {{{
 #!CommitTicketReference repository=""
 revision="67da22f08e05018ea968fcacbac9ac37ea925d85"
 Fixed #34074 -- Added headers argument to RequestFactory and Client
 classes.
 }}}

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070184758fa79d-9fa1bd03-df74-4bf1-9dd2-e6e68fd7b135-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-11-14 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  assigned
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * stage:  Accepted => Ready for checkin


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/010701847572a0ca-c79dc43d-c21c-4d59-bea5-579aefd5f4d3-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-11-12 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  assigned
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by David Wobrock):

 * needs_better_patch:  1 => 0


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/010701846cb0dfcc-d52a65f9-9418-42e8-8bbd-318345ca07af-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-11-10 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  assigned
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * needs_better_patch:  0 => 1


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018460e75944-707fe6d4-086d-4f1a-8f0e-75e58e970658-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-10-14 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  assigned
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by David Wobrock):

 * needs_docs:  1 => 0


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070183d6e36b42-6c32b74b-4530-409b-8a9e-6b7c3f80cc28-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-10-13 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  assigned
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  1
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by David Wobrock):

 * needs_better_patch:  1 => 0
 * needs_docs:  0 => 1


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070183d248264a-e9bf7070-3577-4dd4-a0d9-100a71a6b249-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-10-12 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  assigned
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * needs_better_patch:  0 => 1


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070183cb6b8e0a-364e1dbb-923a-4669-9ca2-f77f505f1824-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-10-09 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+-
 Reporter:  Adam Johnson |Owner:  David
 |  Wobrock
 Type:  New feature  |   Status:  assigned
Component:  Testing framework|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by David Wobrock):

 * cc: David Wobrock (added)
 * owner:  nobody => David Wobrock
 * has_patch:  0 => 1
 * status:  new => assigned


Comment:

 I agree that it would come in handy!

 Here's a [https://github.com/django/django/pull/16163 draft PR].

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070183be7e7150-e0f2dfab-a71f-45d5-8928-a70bbf264641-00%40eu-central-1.amazonses.com.


Re: [Django] #34074: 'headers' argument for test RequestFactory/Client

2022-10-08 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
---+
 Reporter:  Adam Johnson   |Owner:  nobody
 Type:  New feature|   Status:  new
Component:  Testing framework  |  Version:  dev
 Severity:  Normal |   Resolution:
 Keywords: | Triage Stage:  Accepted
Has patch:  0  |  Needs documentation:  0
  Needs tests:  0  |  Patch needs improvement:  0
Easy pickings:  0  |UI/UX:  0
---+
Changes (by Mariusz Felisiak):

 * stage:  Unreviewed => Accepted


Comment:

 Sounds good.

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070183b8d36e7f-cc61baa5-0b9e-4cb6-b0ec-159dff70b534-00%40eu-central-1.amazonses.com.


[Django] #34074: 'headers' argument for test RequestFactory/Client

2022-10-07 Thread Django
#34074: 'headers' argument for test RequestFactory/Client
-+
   Reporter:  Adam Johnson   |  Owner:  nobody
   Type:  New feature| Status:  new
  Component:  Testing framework  |Version:  dev
   Severity:  Normal |   Keywords:
   Triage Stage:  Unreviewed |  Has patch:  0
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+
 We have `request.headers` since Django 2.2, but `RequestFactory`, and thus
 `Client`, still require using the awkward meta syntax for setting headers:

 {{{
 self.client.get("/", HTTP_ACCEPT_LANGUAGE="en")
 }}}

 I propose we add support for a `headers` argument that takes a dictionary
 like `request.headers`:

 {{{
 self.client.get("/", headers={"accept-language": "en"})
 }}}

 This would make tests easier to read and write, since they’d be consistent
 with `HttpRequest`.

 (If this is accepted and merged, open a [https://github.com/adamchainz
 /django-upgrade/ django-upgrade] issue to rewrite request factory and
 client invocations.)

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070183b17ed419-4924fa1b-5a35-4954-b6d5-938c8772cc98-00%40eu-central-1.amazonses.com.