public void WriteLineTest1()
 {
     TextWriter[] streamsArray = null; // TODO: 初始化为适当的值
     MultiTextWriter target = new MultiTextWriter( streamsArray ); // TODO: 初始化为适当的值
     string strLine = string.Empty; // TODO: 初始化为适当的值
     target.WriteLine( strLine );
     Assert.Inconclusive( "无法验证不返回值的方法。" );
 }
 public void EncodingTest()
 {
     TextWriter[] streamsArray = null; // TODO: 初始化为适当的值
     MultiTextWriter target = new MultiTextWriter( streamsArray ); // TODO: 初始化为适当的值
     Encoding actual;
     actual = target.Encoding;
     Assert.Inconclusive( "验证此测试方法的正确性。" );
 }
Пример #3
0
        /// <summary>
        /// 4) 获取运行程序的参数处理
        /// </summary>
        private static void InitServerArgumentsDisposal(string[] args)
        {
            // 完成服务端的基本初始设置后,配置OneServer一次
            if ( EventConfigServer != null )
                EventConfigServer( ref s_ConfigServer );

            if ( s_ConfigServer.IsChangeDebug == true )
                s_Debug = s_ConfigServer.Debug;

            if ( s_ConfigServer.IsChangeService == true )
                s_Service = s_ConfigServer.Service;

            if ( s_ConfigServer.IsChangeProfiling == true )
                s_Profiling = s_ConfigServer.Profiling;

            if ( s_ConfigServer.IsChangeCache == true )
                s_Cache = s_ConfigServer.Cache;

            if ( s_ConfigServer.IsChangeHaltOnWarning == true )
                s_HaltOnWarning = s_ConfigServer.HaltOnWarning;

            // 初始化
            if ( s_ConfigServer.IsChangeServerNetConfig == true )
                Mmose.Net.Server.Init( s_ConfigServer.m_iServerCachedSize, s_ConfigServer.m_iServerBufferSize, s_ConfigServer.m_iServerManageThreadPoolSize, s_ConfigServer.m_iServerSendThreadPoolSize, s_ConfigServer.m_iServerReceiveThreadPoolSize, s_ConfigServer.m_iServerProcessThreadPoolSize, s_ConfigServer.m_iServerMaxClients, s_ConfigServer.m_iServerOutTimeInterval );
            else
                Mmose.Net.Server.InitDefault();

            // 初始化
            if ( s_ConfigServer.IsChangeClientNetConfig == true )
                Mmose.Net.Client.Init( s_ConfigServer.m_iClientCachedSize, s_ConfigServer.m_iClientBufferSize, s_ConfigServer.m_iClientManageThreadPoolSize, s_ConfigServer.m_iClientSendThreadPoolSize, s_ConfigServer.m_iClientReceiveThreadPoolSize, s_ConfigServer.m_iClientProcessThreadPoolSize, s_ConfigServer.m_iClientOutTimeInterval );
            else
                Mmose.Net.Client.InitDefault();

            for ( int iIndex = 0; iIndex < args.Length; iIndex++ )
            {
                string strArg = args[iIndex];

                if ( Insensitive.Equals( strArg, "-Debug" ) )
                    s_Debug = true;
                else if ( Insensitive.Equals( strArg, "-Service" ) )
                    s_Service = true;
                else if ( Insensitive.Equals( strArg, "-Profile" ) )
                    s_Profiling = true;
                else if ( Insensitive.Equals( strArg, "-NoCache" ) )
                    s_Cache = false;
                else if ( Insensitive.Equals( strArg, "-HaltOnWarning" ) )
                    s_HaltOnWarning = true;
            }

            if ( s_Service == true )
            {
                if ( Directory.Exists( "../Logs" ) == false )
                    Directory.CreateDirectory( "../Logs" );

                if ( s_ConfigServer.IsChangeLogFile )
                    s_FileLogger = new FileLogger( "../Logs/" + s_ConfigServer.LogFile );
                else
                    s_FileLogger = new FileLogger( "../Logs/Console.log" );

                Console.SetOut( s_MultiConOut = new MultiTextWriter( Console.Out, s_FileLogger ) );
            }
            else
                Console.SetOut( s_MultiConOut = new MultiTextWriter( Console.Out ) );
        }
 public void WriteTest()
 {
     TextWriter[] streamsArray = null; // TODO: 初始化为适当的值
     MultiTextWriter target = new MultiTextWriter( streamsArray ); // TODO: 初始化为适当的值
     char charWrite = '\0'; // TODO: 初始化为适当的值
     target.Write( charWrite );
     Assert.Inconclusive( "无法验证不返回值的方法。" );
 }
 public void MultiTextWriterConstructorTest()
 {
     TextWriter[] streamsArray = null; // TODO: 初始化为适当的值
     MultiTextWriter target = new MultiTextWriter( streamsArray );
     Assert.Inconclusive( "TODO: 实现用来验证目标的代码" );
 }
 public void AddTest()
 {
     TextWriter[] streamsArray = null; // TODO: 初始化为适当的值
     MultiTextWriter target = new MultiTextWriter( streamsArray ); // TODO: 初始化为适当的值
     TextWriter textWriter = null; // TODO: 初始化为适当的值
     target.Add( textWriter );
     Assert.Inconclusive( "无法验证不返回值的方法。" );
 }