(self)
| 2094 | # RemovedInDjango70Warning. |
| 2095 | @ignore_warnings(category=RemovedInDjango70Warning) |
| 2096 | def test_auth_conflict(self): |
| 2097 | msg = ( |
| 2098 | "auth_user and auth_password cannot be used with a connection. " |
| 2099 | "Pass auth_user and auth_password to get_connection() instead." |
| 2100 | ) |
| 2101 | for param in ["auth_user", "auth_password"]: |
| 2102 | with ( |
| 2103 | self.subTest(param=param), |
| 2104 | self.assertRaisesMessage(TypeError, msg), |
| 2105 | ): |
| 2106 | send_mail( |
| 2107 | "subject", |
| 2108 | "body", |
| 2109 | "from@example.com", |
| 2110 | ["to@example.com"], |
| 2111 | **{param: "value"}, |
| 2112 | connection=mail.get_connection(), |
| 2113 | ) |
| 2114 | |
| 2115 | # RemovedInDjango70Warning. |
| 2116 | @ignore_warnings(category=RemovedInDjango70Warning) |
nothing calls this directly
no test coverage detected