You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The InternalTrace class uses a staticwriter which is set in a call to Initialize.
Any caller that gets a ILogger before that call to Initialize is made gets a nullwriter.
InternalTrace.Initialize is called from TestEngine.Initialize.
Before a user can get there, the initializer of TestEngine has called new ServiceContext() which calls new ServiceManager() which calls InternalTrace.GetLogger(). This logger is called with the InternalTraceLevel.Default meaning it will never log anything.
If the user added any services before that call to TestEngine.Initialize none of them would every log either.
To solve this, the InternalTrace.GetLogger calls should not take the writer and DefaultTraceLevel when called, but the ones that are active.
The text was updated successfully, but these errors were encountered:
The
InternalTrace
class uses astatic
writer which is set in a call toInitialize
.Any caller that gets a
ILogger
before that call toInitialize
is made gets anull
writer.InternalTrace.Initialize
is called fromTestEngine.Initialize
.Before a user can get there, the initializer of
TestEngine
has callednew ServiceContext()
which callsnew ServiceManager()
which callsInternalTrace.GetLogger()
. This logger is called with theInternalTraceLevel.Default
meaning it will never log anything.If the user added any services before that call to
TestEngine.Initialize
none of them would every log either.To solve this, the
InternalTrace.GetLogger
calls should not take the writer andDefaultTraceLevel
when called, but the ones that are active.The text was updated successfully, but these errors were encountered: