Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed some issues, improved library and PHPUnit tests #305

Merged
merged 38 commits into from
May 5, 2019
Merged

Conversation

Sebbo94BY
Copy link
Collaborator

@Sebbo94BY Sebbo94BY commented May 1, 2019

commanddotcom and others added 29 commits March 29, 2019 14:36
fixes #150 #167 #122  as discussed at #284 instead of trying to avoid loading attachments rather put it off until it is needed.
we can do the same for text plain and text html as well, what you don't need won't be retrieved.
solution remains non breaking, public lazy load properties are implemented as property magic getter
Function to parse datetime correctly RFC2822 + tests
Added some more information and improved the sample code
Added line break to sample code in order to avoid side-scrolling effect
phpunit is not required in production, only for development.
@Sebbo94BY Sebbo94BY requested a review from barbushin May 1, 2019 20:21
@Sebbo94BY Sebbo94BY added documentation Related to the documentation. enhancement This will enhance this library. labels May 1, 2019
@Sebbo94BY
Copy link
Collaborator Author

@barbushin please verify and merge, if it's ok from your side as well.

$ phpunit --testdox
PHPUnit 7.5.9 by Sebastian Bergmann and contributors.

Runtime:       PHP 7.1.26-2+0~20190216175340.13+stretch~1.gbpc20626
Configuration: /home/sebastian/git/php-imap/phpunit.xml

Mailbox
 ✔ Constructor [4.25 ms]
 ✔ Constructor trims possible variables [0.37 ms]
 ✔ Server encoding has default setting and only use supported settings [0.53 ms]
 ✔ Set and get server encoding [0.06 ms]
 ✔ Imap search option has a default [0.05 ms]
 ✔ Set and get imap search option [0.10 ms]
 ✔ Get login [0.05 ms]
 ✔ Path delimiter has a default [0.39 ms]
 ✔ Path delimiter is being checked [0.10 ms]
 ✔ Set and get path delimiter [0.07 ms]
 ✔ Encoding returns correct values [0.37 ms]
 ✔ Parsed date different time zones [0.59 ms]
 ✔ Parsed date time with empty header date [0.07 ms]
 ✔ Mime encoding [0.39 ms]
 ✔ Set timeouts [1135.19 ms]
 ✔ Set connection args [0.18 ms]

Requirements
 ✔ Php imap extension is enabled [0.24 ms]

Time: 1.18 seconds, Memory: 4.00 MB

OK (17 tests, 98 assertions)

Everything, what changed (eg. ability to change the IMAP search option from SE_UID to SE_FREE) has the previous defaults, that users don't need to change their applications code, when they update php-imap.

This PR solves the in the PR description mentioned issues.

@Sebbo94BY
Copy link
Collaborator Author

@barbushin can we merge and release these changes?

@Sebbo94BY Sebbo94BY merged commit ff84254 into master May 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Related to the documentation. enhancement This will enhance this library.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants