Esempio n. 1
0
        public void InitStressTest()
        {
            MainWindow.InitIPAdressComboBox(MainWindow.Instance.stress_comboBoxIPAddress, ServerAddressRegistry.GetServerAddresses(1));

            InputMethod.SetIsInputMethodEnabled(MainWindow.Instance.UserBeginIdNum, false);


            MainWindow.Instance.PreFixUserID.Text   = ServerAddressRegistry.ReadValue(MainWindow.SAVE_PREFIX_KEY_ID, "Braves");
            MainWindow.Instance.UserBeginIdNum.Text = ServerAddressRegistry.ReadValue(MainWindow.SAVE_USER_BEGIN_NUM_KEY_ID, "3000");

            MainWindow.Instance.TenKBInGroupUserCount.Text = ServerAddressRegistry.ReadValue(MainWindow.SAVE_TENKBGRUCOUNT_KEY_ID, "50");
            MainWindow.Instance.TenKBMaxUserNumber.Text    = ServerAddressRegistry.ReadValue(MainWindow.SAVE_TENKBMAXUSERCOUNT_KEY_ID, "100");

            MainWindow.Instance.MatchInGroupUserCount.Text = ServerAddressRegistry.ReadValue(MainWindow.SAVE_MATCHGRUCOUNT_KEY_ID, "50");
            MainWindow.Instance.MatchKBMaxUserNumber.Text  = ServerAddressRegistry.ReadValue(MainWindow.SAVE_MATCHMAXUSERCOUNT_ID, "100");

            MainWindow.Instance.TestLoginInGroupUserCount.Text = ServerAddressRegistry.ReadValue(MainWindow.SAVE_LOGINTGRUCOUNT_KEY_ID, "50");
            MainWindow.Instance.TestLoginMaxUserNumber.Text    = ServerAddressRegistry.ReadValue(MainWindow.SAVE_LOGINTMAXUSERCOUNT_ID, "100");


            mDataTestWin.InitStressTest();
            mMatcingTestWin.InitStressTest();
            mMatched10KBTestWin.InitStressTest();
            mLoginTestWin.InitStressTest();
        }
Esempio n. 2
0
        public MainWindow()
        {
            InitializeComponent();

            Instance = this;

            SF.GlobalEngine.Start("TestNet.WInSharp");


            using (RegistryKey key = Registry.CurrentUser.CreateSubKey(RegistryKeyName))
            {
            }

            string IniFilePath = string.Format("{0}/default.ini", System.IO.Directory.GetCurrentDirectory());

            if (!ServerAddressRegistry.ReadServerAddress(0))
            {
                ServerAddressRegistry.SetDefaultServerAddress(0, IniFilePath);
            }

            if (!ServerAddressRegistry.ReadServerAddress(1))
            {
                ServerAddressRegistry.SetDefaultServerAddress(1, IniFilePath);
            }

            ServerAddressRegistry.ReadLoginID();

            int MaxUserValue = 400;

            if (ServerAddressRegistry.ReadMaxUser(IniFilePath, ref MaxUserValue))
            {
                StressTestWindowDataTest.MaxUser  = MaxUserValue;
                StressTestWindowMatchTest.MaxUser = MaxUserValue;
                StressTestWindowLoginTest.MaxUser = MaxUserValue;
            }

            mSimpleTestWin.InitSimpleTest();
            mStressTestWin.InitStressTest();

            int TabIndex = Convert.ToInt32(ServerAddressRegistry.ReadValue(SAVE_TAB_INDEX_ID, "0"));

            StressTestTab.SelectedIndex = TabIndex;
        }