Opened 10 years ago
Closed 10 years ago
#36658 closed enhancement (fixed)
Adding method to reset the mocked phpmailer instance
| Reported by: | welcher | Owned by: | boonebgorges |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.6 |
| Component: | Build/Test Tools | Version: | |
| Severity: | normal | Keywords: | has-patch dev-feedback |
| Cc: | Focuses: |
Description
Added a new decorator method to rest the mock phpmailer object to make it more clear as to what the code is doing. Also, I removed the tests_ prefix from the retrieve_phpmailer_instance method as it is not needed and may cause confusion as it does not contain any tests.
Attachments (2)
Change History (7)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
The reset method looks good to me.
I think the
tests_prefix on the function is meant to be a namespace - seetests_add_filter(). I am wary of changing it just for aesthetic reasons, as there may be third-party libraries using it. Could you change it back and post an updated patch?