Skip to content

do not cache logger when running unit tests#28313

Merged
individual-it merged 1 commit into
masterfrom
fix-logger-phpunit
Jul 10, 2017
Merged

do not cache logger when running unit tests#28313
individual-it merged 1 commit into
masterfrom
fix-logger-phpunit

Conversation

@individual-it

Copy link
Copy Markdown
Member

Description

when running unit tests the logger should not be cached to make it possible to mock it

Related Issue

file firewall unit tests were failing after #28215

Screenshots (if appropriate):

travis run on firewall tests before fix
bildschirmfoto von 2017-07-05 15-40-34

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@individual-it

Copy link
Copy Markdown
Member Author

after this fix unit tests of firewall app are passing again locally and on travis
test-passing

@davitol

davitol commented Jul 10, 2017

Copy link
Copy Markdown
Contributor

@aneumann IMHO this PR doesn't look like the best approach to solve the tests problem... No idea how to fix them, but I guess adding code related to tests in server.php is not a good idea.

@PVince81

Copy link
Copy Markdown
Contributor

I don't have any better idea. @individual-it can you add a PHP comment to explain why this change is needed ?

@PVince81 PVince81 modified the milestones: development, 10.1 Jul 10, 2017
@individual-it

Copy link
Copy Markdown
Member Author

@PVince81 does this comment make it understandable what happens?

@PVince81 PVince81 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Comment thread lib/private/Server.php Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

except then? or except when

@individual-it individual-it merged commit 973e19a into master Jul 10, 2017
@individual-it individual-it deleted the fix-logger-phpunit branch July 10, 2017 14:47
@phil-davis

Copy link
Copy Markdown
Contributor

@PVince81 @DeepDiver1975 @individual-it
See 👎 in backport PR #28360
What to do now?

@lock

lock Bot commented Aug 3, 2019

Copy link
Copy Markdown

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock Bot locked as resolved and limited conversation to collaborators Aug 3, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants